//* Use of variables - local scope *

#include <stdio.h> int main() { int sum = 0; for (;;) { int data; // in C variables can be declare only at beginning of blocks scanf("%d", &data); if (data<0) break; sum = sum+data; printf("TL: %5d\n", sum); } return(0); }