0
I write a code for table of any no. But it is not working. Please correct it.
#include <stdio.h> int main() { int a, b, c; printf ("enter the number:\n"); scanf("%d", &a); b=0; c = a*b; while(b<11) { printf("%d\n", &c); b = b+1; } return 0; }
3 Answers
+ 1
in c=a*b,b isn't intialized with any value
+ 1
Ankit Agarwal
printf("%d\n", c);
To print, just put c, not &c..
What actually trying to get here? Specify that clearly..
By that it prints c.(= 0), 11 times.
0
It's not working even after initializing