Source_Code stringlengths 69 484k | IR_Original stringlengths 2.05k 17.9M |
|---|---|
#include <stdio.h>
int main(void)
{
int s1,s2=0,e;
for(e=0;e<10;e++){
scanf("%d",&s1);
s2=s1+s2;
}
printf("%d\n",s2);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_272747/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_272747/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main(void)
{
int n,d,x,i,j,c;
scanf("%d%d%d",&n,&d,&x);
int a[n];
for(i=0;i<n;i++)
scanf("%d",&a[i]);
c=0;
for(i=0;i<n;i++){
for(j=0;a[i]*j+1<=d;j++){
c++;
}
}
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_272790/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_272790/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
//#include <stdlib.h>
//#include <string.h>
//#include <stdbool.h>
//#include <limits.h>
//#include <math.h>
int main() {
int n;
scanf("%d", &n);
int d, x, a[n];
scanf("%d%d", &d, &x);
for (int i=0; i<n; i++) scanf("%d", a+i);
int ans = x;
for (int i=0; i<n; i++) ans += (d-1)/a[i] + 1;... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_272833/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_272833/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main(void){
int n, d, x, i, j;
scanf("%d", &n);
scanf("%d%d", &d, &x);
int a[n];
int ans = x;
for(i = 0; i < n; i++){
scanf("%d", &a[i]);
}
for(i = 0; i < n; i++){
for(j = 0; d >= a[i] * j + 1; j++){
ans++;
}
}
printf("%d\n", ans);
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_272877/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_272877/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
void filltill(char a[3][12], int n){
int i;
for(i=0;i<n;i++){
a[0][i] = 'O';
a[1][i] = 'O';
a[2][i] = 'O';
}
}
int main(){
int n;
char a[3][12];
int till;
scanf("%d",&n);
int i,j;
for(i=0;i<12;i++){
for(j=0;j<3;j++){
a[j][i] = '#';
}
}
char odd = '#';
if(n == 0){
}
else
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_27292/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_27292/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_addr ... |
#include<stdio.h>
int main()
{
int man,day,amari;
int choco = 0;
scanf("%d",&man);
scanf("%d",&day);
scanf("%d",&amari);
int temp = 0;
for(int i = 0;i < man;i++){
scanf("%d",&temp);
if(temp > day){
choco += 1;
}
else if(day % temp == 0){
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_272963/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_272963/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
#include<string.h>
int N,D,y,x,f;
char S[105][105];
int main()
{
scanf("%d",&N);
for(;N--;)
{
scanf("%d",&D);
memset(S,0,sizeof(S));
for(y=D,x=1,f=-1;;)
{
if(f!=-1)S[--y][++x]=0;
for(f=0;y>=1&&!S[y-1][x]&&!S[y][x+1]&&!S[y][x-1];y--)
{
f=1;
S[y][x]=1;
}
if(!f)break;
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_273005/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_273005/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <math.h>
#include <string.h>
#include <stdlib.h>
int str_cmp(const void *a,const void *b)
{
return strcmp((char*)a, (char*)b);
}
int main(){
long long int n;
scanf("%lld", &n);
char s[n][11];
long long int a;
for(a=0;a<n;a++)
{
scanf("%s",s[a]);
}
qsort(s,n,sizeof(s[0]),str_cmp... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_273128/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_273128/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
//char S[200010][10];
int compare_string(const void *a, const void *b) {
return strcmp(*(char **)a, *(char **)b);
}
int main(){
int N;
char cmp[10];
char **S;
int flag=1;
scanf("%d\n",&N);
int i,j,cnt=0;
S = (char**)malloc(sizeof(char*)*N);
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_273186/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_273186/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int main(void)
{
int r, g, b, k = 0;
scanf("%d", &r);
scanf("%d", &g);
scanf("%d", &b);
k = 100 * r + 10 * g + b;
if (k % 4 == 0) {
printf("YES");
}
else {
printf("NO");
}
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_273229/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_273229/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main(void)
{
int r,g,b;
scanf("%d",&r);
scanf("%d",&g);
scanf("%d",&b);
if((g*10 + b) % 4 == 0)
printf("YES");
else
printf("NO");
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_273272/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_273272/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main(void){
int a,b,c,sum;
scanf("%d %d %d",&a,&b,&c);
sum=100*a+10*b+c;
if(sum%4==0){printf("YES");}
else{printf("NO");}
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_273322/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_273322/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main(void){
int a,b,c,d;
scanf("%d %d %d",&a,&b,&c);
d=100*a+10*b+c;
if(d%4==0){
printf("YES");}
else{printf("NO");}
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_273373/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_273373/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main(void){
int r,g,b;
scanf("%d%d%d",&r,&g,&b);
if((r*100+g*10+b)%4==0) printf("YES");
else printf("NO");
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_273416/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_273416/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
#include<string.h>
int main()
{
char in[20];
int zero,non,k,i;
scanf("%s",in);
scanf("%d",&k);
for(zero=non=0,i=strlen(in)-1;i>=0;i--)
{
if(in[i]=='0')
zero++;
else
non++;
if(zero==k)
{
printf("%d\n",non);
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_27346/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_27346/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_addr ... |
#include<stdio.h>
int main(void) {
int r, g, b,num;
char buf[128];
fgets(buf,128,stdin);
sscanf(buf,"%d %d %d",&r,&g,&b);
num = r*100 + g*10 + b*1;
if(num%4 == 0) {
printf("YES");
} else {
printf("NO");
}
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_273502/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_273502/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@stdin = external local_unn... |
#include<stdio.h>
#include<string.h>
int main (void){
int r,g,b,n;
while(scanf("%d%d%d",&r,&g,&b)!=EOF){
n=r*100 + g*10 +b;
if(n%4==0){
printf("YES");}
else printf("NO");
}
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_273553/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_273553/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int main(){
int a,b,c;
scanf("%d %d %d",&a,&b,&c);
if((b*10+c)%4==0) printf("YES\n");
else printf("NO\n");
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_273597/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_273597/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int main(void)
{
int i,n,c=0;
char a,dammy;
scanf("%d%c",&n,&dammy);
for(i=0;i<n;i++){
scanf("%c%c",&a,&dammy);
if(a=='Y')
c=1;
}
if(c==1)
printf("Four");
else
printf("Three");
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_273647/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_273647/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
#include <stdlib.h>
int main(void) {
int N;
scanf("%d", &N);
int x = 1;
int y;
int i;
char *S;
int a[4] = {0};
S = (char *)malloc(N * sizeof(char));
for(i=0; i<N; i++) {
scanf("%s", &S[i]);
}
for(i=0; i < N; i++) {
switch(S[i]) {
case('P'):
a[0] = 1;
break;
case('W... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_273690/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_273690/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main(void){
int N;
scanf("%d",&N);
int i;
char S;
int c=0;
for(i=0;i<N;i++){
scanf("%c",&S);
if(S == 'Y'){
c = 1;
break;
}
}
if(c == 0) printf("Three");
else printf("Four");
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_273733/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_273733/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int main(){
int i,N;
int judge = 0;
char c;
scanf("%d",&N);
for(i=0;i<N;i++){
scanf(" %c",&c);
if(c=='Y'){
printf("Four");
judge = 1;
break;
}
if(i==N-1&&judge==0){
printf("Three");
}
}
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_273777/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_273777/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int main (void)
{
int N,i;
int a[20];
int b[20];
int c[20];
int val;
char bin;
int satisfy = 0;
//はいんねえ
scanf("%d",&N);
scanf("%c",&bin);
for(i=0;i<N;i++){
scanf("%d ",&a[i]);
//printf("got %d\n",a[i]);
//scanf("%c",&bin);
}
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_273863/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_273863/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main()
{
int N;
int a[100];
int b[100];
int c[100];
int out = 0;
scanf("%d", &N);
for (int i = 0; i < N; i++) scanf("%d", &a[i]);
for (int i = 0; i < N; i++) scanf("%d", &b[i]);
for (int i = 0; i < N-1; i++) scan... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_273906/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_273906/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main() {
int i;
int N;
int A[20], B[20], C[20];
int ans = 0;
scanf("%d", &N);
for (i = 0; i < N; i++) {
scanf("%d", &A[i]);
A[i] -= 1;
}
for (i = 0; i < N; i++) {
scanf("%d", &B[i]);
}
for (i = 0; i < N - 1; i++) {
scanf("%d", &C[i]);
}
for (i = 0; i < N; i++) {
ans +=... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_273957/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_273957/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main(void)
{
int n, sum;
char cmd[24];
while (scanf("%d", &n) != EOF) {
sum = 0;
while (n--) {
scanf("%s", cmd);
if (cmd[1] == '+') sum++;
else sum--;
}
printf("%d\n", sum);
}
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_2740/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_2740/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_addr co... |
#include<stdio.h>
int bonuse(int *a, int *c){
int tmp = 0;
do{
if(*(a + 1) - *a == 1){
tmp += c[*a - 1];
}
*a++;
}while(*(a + 1));
return tmp;
}
int sumb(int *b){
int tmp = 0;
int i;
do{
tmp += *b;
}while(*b++);
return tmp;
}
int main... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_274042/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_274042/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <string.h>
#include <limits.h>
#include <stdlib.h>
#include <math.h>
int main(void)
{
long int i, j;
long int n, k;
long int sum;
long int max;
long int count;
long int a[100];
long int b[100];
long int c[100];
scanf("%ld", &n);
for(i = 0; i < n; i++) {
scanf("%ld", &a[i]);... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_274086/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_274086/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main(){
int n,i,j,k,a[20],b[20],c[20],s;
scanf("%d",&n);
for (i=0;i<n;i++) scanf("%d",&a[i]);
for (i=0;i<n;i++) scanf("%d",&b[i]);
for (i=0;i<n-1;i++) scanf("%d",&c[i]);
k=-9;
for (s=i=0;i<n;i++) {
j=a[i]-1;
s+=b[j];
if (j==k+1) s+=c[k];
k=j;
}
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_274129/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_274129/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
#include <ctype.h>
#include <limits.h>
#define inf (INT_MAX-1)
#define INF 9223372036854775807
#define sq(n) ((n)*(n))
#define rep(i,n) for(i=0;i<n;i++)
#define rev(i,n) for(i=n-1;i>=0;i--)
#define sort(a,n) qsort(a,n,sizeof(TYPE),cmp)
#defin... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_274172/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_274172/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@mod = dso_local local_unna... |
#include <stdio.h>
int main(void){
int a,b,n,t;
int i;
while(scanf("%d %d %d",&a,&b,&n)!=EOF){
//printf("%d,%d,%d\n",a,b,n);
int s=0;
t=a/b;
a-=b*t;
a*=10;
for(i=0;i<n;i++){
t=a/b;
a-=b*t;
a*=10;
s+=t;
if(a==0) break;
}
printf("%d\n",s);
}
return... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_274215/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_274215/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
// Aizu Vol-1 0138: Track and Field Competition
// 2017.8.2
#include <stdio.h>
#include <stdlib.h>
#include <ctype.h>
char *gets(char *);
char buf[50], *p;
#define INF 1000000
typedef struct { int n, t; } R;
R s[4][8], a[4][2];
int getDouble(void)
{
int len = 0, n = 0;
while (isspace(*p)) p++;
while (isdigit(*p... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_274280/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_274280/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
%struct.R = type { i32, i32... |
#include <stdio.h>
int main(void)
{
int t;
int n;
while (scanf("%d", &t), t != 0){
scanf("%d", &n);
while (n-- > 0){
int s, f;
scanf("%d %d", &s, &f);
t -= f - s;
}
if (t <= 0){
puts("OK");
}
else {
printf("%d\n", t);
}
}
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_274323/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_274323/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main()
{
int i, t, s, f, n, a;
scanf("%d", &t);
while (t > 0) {
a = 0;
scanf("%d", &n);
for (i = 0; i < n; i++) {
scanf("%d %d", &s, &f);
a += (f - s);
}
if (a < t)
printf("%d\n", t - a);
else
printf("OK\n");
scanf("%d", &t);
}
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_274367/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_274367/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int main()
{
int len,array[105],last=4,count=0,i;
scanf("%d",&len);
for(i=1;i<=len;i++)
scanf("%d",&array[i]);
for(i=1;i<=len;i++)
{
if(array[i]==0)
{
count++;
last=4;
}
else if(array[i]==1)
{
if(last==1)
{
count++;
last=4;
}
else
last... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_27441/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_27441/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_addr ... |
#include<stdio.h>
void main(){
long long int x, money=100, year=0;
scanf("%lld",&x);
while(x>money){
money *= 1.01;
year++;
}
printf("%lld",year);
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_274453/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_274453/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main(void){
long long x,cnt=0,k=100;
scanf("%lld",&x);
while(k<x){
k += k/100;
cnt++;
}
printf("%lld",cnt);
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_274497/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_274497/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int main()
{
int m,n,arr[205];
scanf("%d",&n);
int i,sum=0;
for(i=0;i<n;i++)
{
scanf("%d",&arr[i]);
if(arr[i]==0)
{
sum++;
}
}
//printf("%d\n",sum);
for(i=0;i<n;i++)
{
if(arr[i]==1 || arr[i]==2)
break;
}
int ans=i;
//printf("%d\n",ans);
/*for(i=ans;i<n-1;i++)
{
if(ar... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_27454/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_27454/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_addr ... |
#include <stdio.h>
int main(){
long int X;
long int m = 100;
scanf("%ld", &X);
int cnt = 0;
while(m<X){
m += m * 0.01;
cnt += 1;
}
printf("%d", cnt);
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_274583/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_274583/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
#include<stdlib.h>
int main (void){
long X;
long deposit = 100;
int years = 0;
scanf("%ld",&X);
long rishi = 0;
while(deposit<X){
years ++;
deposit += deposit / 100;
}
printf("%d",years);
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_274626/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_274626/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main(void) {
// your code goes here
int n;scanf("%d",&n);
char inp[n];scanf("%s",inp);
int i,arr[n];
int mark[n];
for(i=0;i<n;i++)
{
scanf("%d",&arr[i]);
mark[i]=0;
}
int flag=0;
for(i=0;i<n-1;i++)
{
if(inp[i]=='R' && inp[i+1]=='L')
{
flag=1;
mark... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_27467/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_27467/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_addr ... |
#include <stdio.h>
int main (void) {
long X, sum = 100;
int year = 0;
scanf("%ld", &X);
while (X > sum) {
sum = (long)(sum * 1.01);
year++;
}
printf ("%d", year);
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_274712/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_274712/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int main()
{
unsigned long long a = 100;
unsigned long long x;
scanf("%lld",&x);
int year = 1;
// printf("%d",x);
while(1){
a = a + a*0.01;
if(a >= x){
printf("%d",year);
return 0;
}
year ++;
// printf("%d %d\n",a,year);
}
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_274763/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_274763/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
#include<stdlib.h>
#include<string.h>
#include<stdbool.h>
#include<math.h>
#include<limits.h>
typedef long long ll;
int main(){
ll X;
scanf("%lld",&X);
ll year = 0,money = 100;
while(money < X){
money *= 1.01;
year++;
}
printf("%lld",year);
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_274813/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_274813/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
#include<string.h>
int main(void)
{
char s[100005];
int K,i=0,len;
scanf("%s", s);
scanf("%d", &K);
len = strlen(s);
for (i = 0; i < len; i++) {
if ('z' - s[i] +1<=K&&'z'-s[i]+1!=26) {
K -= 'z' - s[i] + 1;
s[i] = 'a';
}
else {
K -= 0;
}
if (K == 0)break;
}
if (K != 0) ... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_274857/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_274857/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#define MAXNUMS 1000000
#define MAXGAPS 13
void ShellSort(int line[], const long n);
void InsertionSort(int line[], const long n, const long gap);
int main(void)
{
long i;
long num_line;
scanf("%ld", &num_line);
int line[MAXNUMS];
for (i = 0; i < num_line; i++) {
scan... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_274907/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_274907/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
short int a[10000000];
int n,x,max=0,t[10];
int main(void){
scanf("%d",&n);
for(;n>10;n-=10){
scanf("%d %d %d %d %d %d %d %d %d %d",&t[0],&t[1],&t[2],&t[3],&t[4],&t[5],&t[6],&t[7],&t[8],&t[9]);
for(x=0;x<10;x++){a[t[x]]++;if(max<t[x])max=t[x];}
}
for(;n>0;n--){scanf("%... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_275014/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_275014/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@max = dso_local local_unna... |
#include<stdio.h>
#include<math.h>
int main(void)
{
int a,b;
scanf("%d%d",&a,&b);
int i,j,n,m,tmp,cnt=0;
for(i=a;i<=b;i++){
tmp = i;
n = tmp;
m = 0;
for(j=1;j<6;j++){
m += (tmp%10)*(int)pow(10,5-j);
tmp /= 10;
}
if(n==m)
cnt++;
}
printf("%d\n",cnt);
return 0;... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_275115/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_275115/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <stdlib.h>
// 標準入力から改行かスペースまで読み取り、数字として返す
int get_num() {
// 10文字+区切り文字までしか受け付けられない
char s[11];
int i, n;
for (i = 0; i < sizeof(s); i++) {
s[i] = getchar();
if (s[i] == ' ' || s[i] == '\n') {
s[i] = '\0';
break;
}
}
ss... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_275159/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_275159/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main(void)
{
int A, B;
int c=0;
scanf("%d%d", &A, &B);
for(int i=A;i<=B;i++){
int n=i;
int ind=0;
int x[5]={};
while(n>0){
x[ind]=n%10;
n/=10;
ind++;
}
int res=1;
for(int j=0;j<(ind-1)/2;j+... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_275201/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_275201/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <string.h>
int main (void){
int a,b;
int count = 0;
scanf("%d %d", &a, &b);
int h[5];
for(int i = a; i <= b; i++){
int tmp = i;
for(int j = 0; j < 5; j++){
h[j] = tmp%10;
tmp /= 10;
}
if( h[0] =... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_275245/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_275245/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
int main()
{
int num=0,i,ge,shi,bai,qian,wan,a,b;
scanf("%d%d",&a,&b);
for (i=a;i<=b;i++)
{
ge=i%10;
shi=i%100/10;
//bai=i%1000/100;
qian=i%10000/1000;
wan=i/10000;
if (ge==wan&&shi==qian)
{
num++;
}
}
print... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_275302/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_275302/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main(void){
int n,i,cnt=1;
int a[20];
scanf("%d",&n);
for(i=0;i<n;i++) scanf("%d",&a[i]);
int max=a[0];
for(i=1;i<n;i++){
if(max<=a[i]){
cnt++;
max=a[i];
}
}
printf("%d",cnt);
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_275346/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_275346/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int bin_search(int x, int *sum, int high)
{
int low=0,mid;
while(low <= high)
{
mid = (low+high)/2;
if(mid == 0 && sum[mid] >= x)
break;
else if(mid != 0 && (sum[mid] >= x && sum[mid-1] < x))
break;
else if(sum[mid] > x && sum[mid-1] >= x)
high = mid-1;
else if(sum[mid] < x)
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_27539/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_27539/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_addr ... |
#include<stdio.h>
int main(void){
/* 変数の宣言 */
int N=0,Ni[20],max=0,result=0;
scanf("%d", &N);
for (int i = 0; i < N; i++){
scanf("%d", &Ni[i]);
}
for(int i=0;i<N;i++){
if(Ni[i]>=max){
max=Ni[i];
result++;
}
}
printf("%d",result);
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_275432/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_275432/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main(void){
int n, i, j, view, flag;
view=1;
scanf("%d", &n);
int height[n];
for(i=1;i<n;i++){
scanf("%d ", &height[i]);
}
scanf("%d", &height[n]);
for(i=2;i<=n;i++){
flag=1;
for(j=1;j<i;j++){
if(height[j]>height[i]){
flag=0;
}
}
if(flag){
v... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_275476/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_275476/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <ctype.h>
void print_int(int n)
{
printf("%d\n",n);
}
void swap(int * a, int * b)
{
int t = *a;
*a = *b;
*b = t;
}
void sort(int a[], int n)
{
for(int i = 1; i < n; i++)
{
int j = i-1;
while(j >= 0 && a[j+1] > a[j])
{
swap(&a[j+1... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_275519/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_275519/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int main(){
int sum=0,N,H,i,max=0;
scanf("%d",&N);
for(i=0;i<N;i++){
scanf("%d",&H);
if(H>=max){
sum++;
max=H;
}
}
printf("%d\n",sum);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_275562/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_275562/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int main(){
int N,i,j,sum=1;
int flag;
scanf("%d", &N);
int H[N];
for(i=0;i<N;i++){
scanf("%d", &H[i]);
}
for(i=1;i<N;i++){
flag=0;
for(j=0;j<i;j++){
if(H[j]>H[i]){
flag = 1;
break;
}
}
if(flag==0) sum++;
}
printf("%d",sum);
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_275605/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_275605/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main() {
int n,h[20],i;
scanf("%d",&n);
for(i=0;i<n;i++) scanf("%d",&h[i]);
int cnt=1,max=h[0];
for(i=1;i<n;i++){
if(h[i-1] <=h[i] && max<=h[i]){
cnt++;
max=h[i];
}
}
printf("%d\n",cnt);
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_275649/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_275649/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
#include<stdlib.h>
#include<math.h>
int main()
{int t,a=0;
scanf("%d",&t);
char s[5];
while(t--){
//int a=0;
scanf("%s",s);
if(s[1]=='+')
a++;
else
a--;
}
printf("%d\n",a);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_2757/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_2757/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_addr co... |
#include <stdio.h>
int main(){
int n;
scanf("%d",&n);
int h[n],max,count;
max = 0;
count = 0;
for(int i = 0; i < n; ++i){
scanf("%d",&h[i]);
if(h[i] >= max){
max = h[i];
count++;
}
}
printf("%d\n",count);
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_275742/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_275742/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#define INRANGE(a,b,c) ((a<=b)&&(b<=c)?(1):(0))
int h,w;
int map[100][100];
int count;
void walk(int x,int y){
map[x][y]=2;
if(INRANGE(0,x-1,h-1)&&map[x-1][y]==1) walk(x-1,y);
if(INRANGE(0,x+1,h-1)<h&&map[x+1][y]==1) walk(x+1,y);
if(INRANGE(0,y-1,w-1)&&map[x][y-1]==1) walk(x,y-1);
if(INRANGE(0,y... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_275786/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_275786/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@map = dso_local global [10... |
#include <stdio.h>
int width,height;
int map[50][50];
void visit(int x,int y) {
int i,j;
if(x<0 || x>=width || y<0 || y>=height)return;
if(map[y][x]==0)return;
map[y][x]=0;
for(i=-1;i<=1;i++) {
for(j=-1;j<=1;j++)visit(x+i,y+j);
}
}
int main(void) {
int i,j;
int result;
while(1) {
scanf("%d%d",&width,&he... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_275843/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_275843/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@width = dso_local global i... |
#include <stdio.h>
#include <math.h>
int main(void){
int q;
double x;
while(1){
scanf("%d",&q);
if(q==-1)
break;
x=(double)q/2;
while(fabs(x*x*x-q)>=0.00001*q)
x=x-(x*x*x-q)/(3*x*x);
printf("%f\n",x);
}
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_275887/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_275887/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
#include<stdlib.h>
#include<stdint.h>
#include<inttypes.h>
#include<math.h>
#include<string.h>
typedef int64_t i64;
typedef int32_t i32;
static void print_int(i64 n){if(n<0){putchar('-');n=-n;}if(n==0){putchar('0');return;}int s[20],len=0;while(n>0){s[len++]=n%10+'0';n/=10;}while(len>0){putchar(s[--... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_27593/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_27593/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_addr ... |
#include <stdio.h>
int main(void)
{
int road[6][2] = {
{1, 2}, {-1, 3}, {1, -1}, {4, 5}, {5, 2}, {2, 1}
};
int i, loc;
char p[128];
while (scanf("%s", p), p[0] != '#'){
i = 0;
loc = 0;
while (p[i] != '\0'){
if (loc != -1){
loc = road[loc][p[i] - '0'];
}
i++;
}
if (loc == 5){
print... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_275973/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_275973/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@__const.main.road = privat... |
#include <stdio.h>
int GCD (int a, int b) {
int c;
c = a % b;
if (c == 0) {
return b;
} else {
return GCD (b, c);
}
}
int main () {
int x, y, z;
while (scanf("%d %d", &x, &y) != EOF) {
z = GCD (x, y);
printf ("%d\n", z);
}
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_276022/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_276022/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
// AOJ 2160: Voronoi Island
// 2018.1.8 bal4u@uu
#include <stdio.h>
#include <string.h>
#include <math.h>
#define EPS 1e-8
typedef struct { double x, y; } PP;
typedef struct { PP s, e; } LINE;
PP pi[11], pc[11];
int dcmp(double x)
{
if (fabs(x) < EPS) return 0;
return x < 0 ? -1 : 1;
}
double cross(double ax, d... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_276088/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_276088/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
%struct.PP = type { double,... |
#include <stdio.h>
int main(){
char s[3];
int cnt=0;
scanf("%s",s);
for (int i=0; i<3; i++) cnt+= s[i]=='1';
printf("%d",cnt);
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_276130/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_276130/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int main(){
int count=0,i;
char s[4];
scanf("%s",s);
for(i=0;i<3;i++)
if(s[i]=='1')
count++;
printf("%d\n",count);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_276181/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_276181/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int main() {
char s[3];
int ans = 0;
scanf("%s", s);
for(int i = 0; i < 3; i++) ans += s[i] == '1';
printf("%d", ans);
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_276275/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_276275/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int main()
{
char s[9];
int c = 0, i = 0;
scanf("%s", s);
for (; i < 3; i++)
{
if (s[i] == '1')
{
c++;
}
}
printf("%d", c);
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_276361/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_276361/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int main(void)
{
char s[4];
scanf("%s",&s);
int i=0;
if(s[0]=='1'){
++i;
}
if(s[1]=='1'){
++i;
}
if(s[2]=='1'){
++i;
}
printf("%d\n", i);
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_276404/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_276404/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main()
{
int cnt=0;
char s[4];
scanf("%s", s);
for (int i=0; i<3; i++) {
if (s[i]=='1') cnt++;
}
printf("%d\n", cnt);
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_276462/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_276462/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main(void){
int a,c=0,i;
for(i=0;i<3;i++){
scanf("%1d",&a);
if(a==1) c++;
}
printf("%d",c);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_276505/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_276505/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int main(void) {
char s[3];
scanf("%c%c%c", &s[0], &s[1], &s[2]);
int cnt = 0;
for (int i = 0; i < 3; i++) {
if (s[i] == '1') cnt++;
}
printf("%d", cnt);
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_276549/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_276549/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
# include <stdio.h>
# include <ctype.h>
int main()
{
int c=0, s;
while( isdigit(s=getchar()))
c+= (s-'0');
printf("%d", c);
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_276592/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_276592/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
// AOJ 2176: For the Peace
// 2017.12.15 bal4u@uu
#include <stdio.h>
#include <string.h>
#define ABS(a) ((a)>=0?(a):-(a))
int pool[10003], sz;
int *c[101], m[101], s[101];
char buf[50003], *p;
int getint()
{
int n = 0;
while (*p >= '0') n = (n<<3) + (n<<1) + (*p++ & 0xf);
p++;
return n;
}
int main()
{
int n,... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_276642/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_276642/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@p = dso_local local_unname... |
#include <stdio.h>
typedef struct {
int key, id;
} data;
typedef struct {
data obj[400001];
int size;
} min_heap;
void push(data x, min_heap* h)
{
int i = ++(h->size);
data tmp;
h->obj[i] = x;
while (i > 1) {
if (h->obj[i].key < h->obj[i>>1].key) {
tmp = h->obj[i>>1];
h->obj[i>>1] = h->obj[i];
h->o... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_276686/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_276686/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
%struct.min_heap = type { [... |
#include<stdio.h>
int main(void)
{
int a,b,c,cnt,x;
scanf("%d %d %d",&a,&b,&c);
cnt=0; x=0;
while(1){
x+=a;
cnt++;
if(cnt%7==0) x+=b;
if(c<=x) break;
}
printf("%d\n",cnt);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_276729/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_276729/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int main(){
int n,m,i,a,b,ans;
scanf("%d %d",&n,&m);
int h[n+1];
int count[n+1];
for(i=1;i<=n;i++){
scanf("%d",&h[i]);
count[i]=1;
}
for(i=1;i<=m;i++){
scanf("%d %d",&a,&b);
if(h[a]>=h[b]){
count[b]=0;
}
if(h[a]<=h[b])
count[a]=0;
}
for(i=1,ans=0;i<=n;i++){
if(count[i]==1)
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_276772/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_276772/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
// #include <stdlib.h>
// const int MAX_TEMBODAI_NUMBER = 9999999;
typedef struct {
int height;
short is_good; // 0: 未定義, 1: 悪い展望台, 2: 良い展望台, 3: 引き分けなので保留
} Tembodai;
// 降順
/* static int compareFunction(const void *lhs, const void *rhs) { */
/* return ((Tembodai *)rhs)->height - ((Tembodai *... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_276815/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_276815/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
%struct.Tembodai = type { i... |
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
int gcd(int a,int b);
int compare(const void* a, const void* b);
int main(void){
int N;
int M;
int add;
int i,j,k,ret;
long h;
long H[100000];
long Hr[100000];
int start[100000]; //M番目の道の始点
int end[100000]; //M番目の道の終点
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_276866/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_276866/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main() {
int n, m, h[200000], dd[200010] = { 0 }, ans = 0;
scanf("%d%d", &n, &m);
for (int i = 0; i < n; i++) {
scanf("%d", &h[i]);
}
for (int i = 0; i < m; i++) {
int s, t;
scanf("%d%d", &s, &t);
if (h[s-1] >= h[t-1])dd[t]++;
if (h[s-1] <= h[t-1])dd[s]++;
}
for (int i = 1; i <=... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_276909/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_276909/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
#include<stdlib.h>
#include<string.h>
#include<math.h>
typedef long long ll;
int h[100008];
int flag[100008];
int a[100008];
int b[100008];
int main(){
int n,m;
int i;
int cnt = 0;
scanf("%d %d", &n, &m);
for(i = 1;i <= n;i++){
scanf("%d", &h[i]);
flag[i] = 1;
}
for(i = 0;i ... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_276952/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_276952/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
#define mod 998244353
long long sum[10][3000000];
long long base[3000000];
long long tree[3000000];
long long left[3000000];
long long right[3000000];
long long lazy[3000000];
int l,r,value;
void build(int l,int r,int k){
left[k]=l;right[k]=r;
if (l==r){
tree[k]=1;
return;
}
int mid=(l+r)/2;
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_276996/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_276996/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@left = dso_local local_unn... |
#include <stdio.h>
#include <string.h>
int main(){
int n;
scanf("%d", &n);
printf("ABC%d", n);
printf("\n");
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_277089/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_277089/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int main()
{
int n;
while(~scanf("%d",&n))
{
if(n>=100&&n<=999)
printf("ABC%d\n",n);
}
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_277139/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_277139/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
//set many funcs template
//Ver.20190820
#include<stdio.h>
#include<string.h>
#include<stdlib.h>
#include<stdbool.h>
#include<time.h>
#include<assert.h>
#define inf 1072114514
#define llinf 4154118101919364364
#define mod 1000000007
#define pi 3.1415926535897932384
int max(int a,int b){if(a>b){return a;}return b;}
int... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_277377/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_277377/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
%struct.sd = type { i32, i3... |
#include <stdio.h>
int max(int a, int b, int c, int d) {
int max1, max2;
max1 = a > b ? a : b;
max2 = c > d ? c : d;
return max1 > max2 ? max1 : max2;
}
int main(int argc, char const *argv[])
{
int n, sx, sy, x, y, top = 0, left = 0, right = 0, bottom = 0, c;
scanf("%d %d %d", &n, &sx, &sy);
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_27742/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_27742/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_addr ... |
#include <stdio.h>
#include <stdlib.h>
int main () {
int N;
int M;
scanf("%d", &N);
scanf("%d", &M);
int *L = malloc((M + 1) * sizeof(int));
int *R = malloc((M + 1) * sizeof(int));
int start = 0;
int end = 0;
for (int i = 1; i <= M; i++) {
scanf("%d", &L[i]);
scanf... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_277485/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_277485/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int max(int x, int y) {
return x > y ? x : y;
}
int min(int x, int y) {
return x < y ? x : y;
}
int main() {
int N, M;
int i, j;
int L[100000];
int R[100000];
int maxL = 1;
scanf("%d %d", &N, &M);
int minR = N;
for (i = 0; i < M; i++) {
scanf("%d %d", &L[i], &R[i]);
}
for (i = 0;... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_277528/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_277528/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int min(int a,int b){
if(a < b){
return a;
}
return b;
}
int max(int a,int b){
if(a > b){
return a;
}
return b;
}
int main(void){
int N,M;
scanf("%d%d",&N,&M);
int left,right,L,R;
for (int i = 0; i < M; i++) {
scanf("%d%d",&L,&R);
if(i == 0){
left = L;
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_277571/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_277571/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <math.h>
#include <stdbool.h>
#define LL long long
#define INF 1<<31-1
#define LLINF 1<<63-1
#define MIN(x,y) ((x)<(y)?(x):(y))
#define MAX(x,y) ((x)<(y)?(y):(x))
#define MOD 1000000007
#define NUM 100001
int cmp(const void *x,const void *y){
return ... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_277621/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_277621/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <limits.h>
#define max(a, b) (((a) > (b)) ? (a) : (b))
int
main(void)
{
int N;
int M;
scanf("%d %d", &N, &M);
int L;
int R;
int min_R = N;
int max_L = 1;
for (int i = 0; i < M; i++) {... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_277665/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_277665/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
#include<stdlib.h>
#include<stdint.h>
#include<inttypes.h>
#include<string.h>
typedef int32_t i32;
void run (void) {
i32 n;
scanf ("%" SCNi32, &n);
i32 *x = (i32 *) calloc (n + 1, sizeof (i32));
for (i32 i = 1; i <= n; ++i) {
scanf ("%" SCNi32, x + i);
}
x[0] = n * n + 1;
i32 *ans ... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_277708/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_277708/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <stdlib.h>
int min(int a, int b){
return a <= b ? a : b;
}
int main(){
int N, i;
scanf("%d", &N);
char *S = (char *)malloc(sizeof(char) * (N + 2));
scanf("%s", &S[1]);
int *A = (int *)malloc(sizeof(int) * (N + 1));
int *B = (int *)malloc(sizeof(int) * (N + 1));
A[0] = 0;
B[0] = 0;... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_277766/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_277766/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int isprime(int n){
int i;
for(i = 2; i < n; i ++ ){
if(n % i == 0)return 0;
}
return 1;
}
int main(void){
const int NUM = 10000;
int i,n,prime[NUM],p1,q1;
for(i = 2; i < NUM; i ++ ){
prime[i] = isprime(i);
}
while(1){
scanf("%d",&n);
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_277809/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_277809/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int is_prime(int n)
{
int i;
if (n % 2 == 0){
return (0);
}
for (i = 3; i * i <= n; i += 2){
if (n % i == 0){
return (0);
}
}
return (1);
}
int main(void)
{
int n;
int i;
while (scanf("%d", &n) * n != 0){
i = n;
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_277852/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_277852/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.