View Code of Problem 90

#include<stdio.h>
int main()
{
	int a,b;
  	scanf("%d %d",&a,&b);
  	int i,j,k;
  	for(i=a;i<=b;i++)
        {
        	for(j=i;j<=b;j++)
                {
                	for(k=j;k<=b;k++)
                        {
                        	if(a*a+b*b==c*c)
                                {
                                	printf("%d^2+%d^2=%d^2\n",a,b,c);
                                }
                        }
                }
        }
  	return 0;
}
/*
Main.c: In function 'main':
Main.c:13:38: error: 'c' undeclared (first use in this function)
                          if(a*a+b*b==c*c)
                                      ^
Main.c:13:38: note: each undeclared identifier is reported only once for each function it appears in
*/

Double click to view unformatted code.


Back to problem 90