Search
 
SCRIPT & CODE EXAMPLE
 

C

Uri/beecrowd problem no - 1131 solution in C

#include<stdio.h>
int main(){
    int limit = 1,counter = 0,counter1 = 0,counter2 = 0,counter3 = 0;
    while(limit != 2){
        if(limit == 1){
            int score1,score2;
            scanf("%d%d", &score1, &score2);
            if(score1 > score2){
                counter1++;
            }else{
                counter2++;
            }
            if(score1 == score2){
                counter3++;
            }
        }
        printf("Novo grenal (1-sim 2-nao)
");
        counter++;
        scanf("%d", &limit);
    }
    printf("%d grenais
", counter);
    printf("Inter:%d
", counter1);
    printf("Gremio:%d
", counter2);
    printf("Empates:%d
", counter3);
    if(counter1 > counter2){
        printf("Inter venceu mais
");
    }
    if(counter1 < counter2){
        printf("Gremio venceu mais
");
    }
    if(counter2 == counter1){
        printf("Não houve vencedor
");
    }
    return 0;
}
Comment

uri/beecrowd problem no - 1133 solution in C

#include<stdio.h>
int main(){
    int X,Y,i;
    
    scanf("%d%d", &X, &Y);
    
    if(X > Y){
        for(i = Y+1; i < X; i++){
            if(i % 5 == 2 || i % 5 == 3){
                printf("%d
", i);
            }
        }
    }else if(X < Y){
        for(i = X+1; i < Y; i++){
            if(i % 5 == 2 || i % 5 == 3){
                printf("%d
", i);
            }
        }
    }
    return 0;
}
Comment

Uri/Beecrowd problem no - 1149 solution in C

#include<stdio.h>
int main(){
    int A,N,sum = 0,i;
    scanf("%d%d", &A, &N);
    while(N < 0 || N == 0){
        scanf("%d", &N);
    }
    for(i = 0; i < N; i++){
        sum = sum + A + i;
    }
    printf("%d
", sum);
    return 0;
}
Comment

PREVIOUS NEXT
Code Example
C :: converting time in c 
C :: convert c code to c online 
C :: how to delete data and add from file in c language 
C :: Letters and Digits Total 
C :: determination data type in c 
C :: variadic macros c 
C :: BEE/URI problem no 1181 solution in C 
C :: WAP to create Database using array of structure & display it in C 
C :: Odd-Even-inator with function in C 
C :: %d and %i 
C :: escaping characters in hibernate queries 
C :: C program to Increase 1 to all of the given Integer Digit 
C :: fread condition 
C :: ? : em linguagem C 
C :: class to const void * 
C :: online embedded c compiler 
C :: in C char to string 
C :: tableau c 
C :: CODE SOURCE POUR LISTE DOUBLEMENT CHAINEé en c 
Dart :: listview.separated flutter 
Dart :: python change type of elements in list 
Dart :: flutter random pick in list 
Dart :: height appbar flutter 
Dart :: flutter clear all text in textfield 
Dart :: slice string dart 
Dart :: Floating Action Button rectangular shaped (round corners) 
Dart :: how to make appbar transparent in flutter 
Dart :: underscore dart 
Dart :: flutter three line list 
Dart :: foreach loop in list in dart 
ADD CONTENT
Topic
Content
Source link
Name
1+8 =