Quick actions

cmd+k|ctrl+k

Navigation

Languages

BAFO

Snippet info

Language

C

Visibility

public

Author

fernandanoronha.coelho

Created

2019-05-16T12:19:49Z

Updated

2019-05-16T13:23:51Z

#include <stdio.h>

int main(void) {
    int R, teste=0;
    
    scanf("%d", &R);
    while(R>0){
        int A=0, B=0, ta, tb;
    for(int i=0;i<R;i++){

        scanf("%d %d", &ta, &tb);
        A+=ta;
        B+=tb;
    }
    teste ++;
    printf("Teste %d\n", teste);
    if(A>B)
    printf("Aldo\n\n");
    if(B>A)
    printf("Beto\n\n");
    scanf("%d", &R);
    }
    return 0;
}
INFO