1 2 3 4 5 6 7 8 9 10
#include<stdio.h> #include<conio.h> void main() { int n,i,sum=0; printf("Enter\n"); scanf("%d", &n); for(i=1; i<=n; i++){ sum=sum+i } getch(); }
1 2 3 4
Line 17: error: conio.h: No such file or directory In function 'main': Line 8: error: expected ';' before '}' token Line 4: warning: return type of 'main' is not 'int'