View Code of Problem 111

#include<stdio.h>
int main(){
	int a,b,count=0;
	int c[20];
	scanf("%d%d",&a,&b);
	while(a>0&&b>0){
	   c[count]=a+b;
	   count++;
	   scanf("%d%d",&a,&b);
	}
	for(int i=0;i<count;i++){
		printf("%d\n",c[i]);
	}
	return 0;
}

Double click to view unformatted code.


Back to problem 111