Search found 1 match

by souravpaulkundu
Wed Oct 30, 2013 7:35 am
Forum: Volume 100 (10000-10099)
Topic: 10035 - Primary Arithmetic
Replies: 328
Views: 58085

uva 10035 Why WA ?? can not understand .

#include<stdio.h> #include<stdlib.h> int main() { unsigned long int a,b,c,d; int count=0,e=0; while(scanf("%lu%lu",&a,&b)==2) { if(a<1000000000&&b<1000000000) { if(a==0&&b==0) break; while(a>9||b>9) { c=a%10; d=b%10; a=a/10; b=b/10; c=c+d+e; if(c>9) { e=1; count++; } else e=0; } if(count==0) printf(...

Go to advanced search