+ 1
What's wrong with my code?
Q:-Write a C program to multiply three numbers and print the result. Here two numbers have to be taken through assignment statements and the third as a user input. My code #include <stdio.h> void main() { int a=7,b=8,c,d; printf("input third number"); scanf("%d", &c); d = a*b*c; printf(" product = %d", d); }
2 Respostas
+ 7
Sohini Giri, Sec A,Roll No.-05
Your code is correct..
but,
Just change in second line..
Use this `int main()`,instead of `void main`,
because this program execute an integer value.
+ 1
please write 'int main()' instead of 'void main()'