DATE:25-12-2017
C-CODE:
Q)Error Identification - Square Non Negative Number
A number N is passed as the input. If the number is non-negative, then the output must be the square of N. Else the program must print the output as NEGATIVEBut the program given below has error(s) / missing lines of code in it. Please identify and rectify those error(s).
sol:-C-CODE:
Replace printf statement with
printf ("%d",N*N);
printf ("%d",N*N);
0 Comments