#include int main() { int x, sum, status; sum = 0; while ((status = scanf("%d", &x)) == 1) sum += x; if (status != EOF) { fprintf(stderr, "add: non-numeric input\n"); return(1); } printf("%d\n", sum); return(0); }