Source_Code
stringlengths
69
484k
IR_Original
stringlengths
2.05k
17.9M
#include <stdio.h> #include <stdlib.h> int main(void) { char s[200000]; int ans[200000] = { 0 }; scanf("%s", s); int length = 0; while (s[length] != 0) length++; int count = 0; for (int i = 0; i < length; i++) { if (s[i] == 'R') count++; else if (count % 2 == 1) { ans[i - 1] += count / 2 + 1; ans...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249231/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249231/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> typedef long long ll; int main(){ char s[100000]; scanf("%s",s); static int x[100000][3]; int a=1,b=0,i; int y[100000]={0}; x[0][0] = 0; for(i=1;s[i]!='\0';i++){ if(a==0) { if(s[i]=='R'){ a=1; x[b][1] =...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249275/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249275/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> #define INF (1000 * 1000 * 99) struct node_t { int y, x; int cost; }; int mofu = 0; struct node_t nyan[1000 * 1000 * 5]; void qa(int idx) { for (;;) { int midx = idx; int i; for (i = 1; i <= 2; i++) { int cidx = idx * 2 + i; if (cidx < mofu && nyan[midx].cost > ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249325/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249325/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.node_t = type { i32...
#include <stdio.h> #include <string.h> int isok(char*); void siza(char*); int main(void) { char data[100]; while(!feof(stdin)) { if(fgets(data,sizeof(data),stdin)==NULL)break; while(!isok(data))siza(data); printf("%s",data); } return 0; } int isok(char* data) { if(strst...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249376/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249376/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<math.h> int main() { double a,b,n,v,i,j,m,value,x,y; scanf("%lf %lf",&a,&b); scanf("%lf",&n); for(j=1;j<=n;j++){ scanf("%lf %lf %lf",&x,&y,&v); i=sqrt((a-x)*(a-x)+(b-y)*(b-y)); value=i/v; if(j==1){ m=value; } else if(v...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_24947/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_24947/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<math.h> int main() { long long a,b,x,y,n,v,i; double s,t,big; scanf("%lld %lld",&a,&b); scanf("%lld",&n); for(i=0;i<n;i++) { scanf("%lld %lld %lld",&x,&y,&v); s=sqrt(((a-x)*(a-x))+((b-y)*(b-y))); t=s/v; if(i==0) big=t; ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_24952/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_24952/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 i,j; int n,m,a; int h,p,q; int max_h; int amida[1004][104]; while(1){ scanf("%d%d%d",&n,&m,&a); if(n==0 && m==0 && a==0) break; for(i=0;i<1004;i++){ for(j=0;j<n;j++){ amida[i][j] = 0; } } max_h = -1; for(i=0;i<m;i++){ scan...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249563/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249563/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 n, max, ans, i; int main(void){ scanf("%d", &n); for(i=0; i<n; i++){ int za, zb; scanf("%d%d", &za, &zb); if(max < za){ max = za; ans = za + zb; } } printf("%d\n", ans); }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249606/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249606/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,r1,c1,r2,c2,sum1,sum2,rook=0,bish=0,king=0,dif1,dif2; scanf("%d%d%d%d",&r1,&c1,&r2,&c2); sum1=r1+c1; sum2=r2+c2; dif1=r2-r1; dif2=c2-c1; if(dif1<0) dif1=-1*dif1; if(dif2<0) dif2=-1*dif2; if((sum1)%2==(sum2)%2) { if(dif1==dif2) bish=1; else bish=2; } if(d...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_24970/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_24970/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 a[100009],dp[100009]; int min(int c,int v){ if(c>=v) return v; else return c; } int dif(int c,int v){ if(c>=v) return(c-v); else return(v-c); } int main() { int n,k; scanf("%d%d",&n,&k); for(int i=0;i<n;i++) scanf("%d",&a[i]); for(int i=0;i<n;i++) dp[i]=1000000009; dp[0]=0; for(int i=1;i...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249743/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249743/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> #define NMAX 100004 const int INF = 0x3f3f3f3f; int height[NMAX]={0}; int dp[NMAX]; int n,k; int min(int a,int b){ return a<b ? a : b ; } int solve (int x){ int some1=INF; if (x==n) { return 0; } if (dp[x]!=-1) { return dp[x]; } if(x>...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249794/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249794/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" @INF = dso_local local_unna...
#include <stdio.h> #include <stdlib.h> #define min(a, b) ((a) > (b) ? (b) : (a)) #define INT_MAX 0x7fffffff int main(void) { int n, k ; scanf("%d %d", &n, &k); int *arr = malloc(sizeof(int) * n); for(int i = 0; i < n; i++) scanf("%d", &arr[i]); int dp[100001] = { [ 0 ... 100000 ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249837/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249837/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> int main(void){ double x1, y1, x2, y2; double distance; scanf("%lf %lf %lf %lf", &x1, &y1, &x2, &y2); distance = sqrt( pow(x1-x2, 2) + pow(y1-y2, 2) ); printf("%.8f", distance); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249888/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249888/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> int main(void){ double x1,y1,x2,y2; scanf("%lf",&x1); scanf("%lf",&y1); scanf("%lf",&x2); scanf("%lf",&y2); printf("%f\n",sqrt((x1-x2)*(x1-x2)+(y1-y2)*(y1-y2))); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249930/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249930/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> int main(void){ double x1,x2,y1,y2; double ans; scanf("%lf %lf %lf %lf",&x1,&y1,&x2,&y2); ans=sqrt((x2-x1)*(x2-x1)+(y2-y1)*(y2-y1)); printf("%f",ans); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249981/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249981/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> int main(void){ double x1,y1,x2,y2; scanf("%lf",&x1); scanf("%lf",&y1); scanf("%lf",&x2); scanf("%lf",&y2); printf("%f\n",sqrt((x1-x2)*(x1-x2)+(y1-y2)*(y1-y2))); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250022/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250022/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...
/* ITP1_10_A */ #include <stdio.h> #include <math.h> /* ??§?¨?????§??????? */ typedef struct coordinate_value { double x; double y; } point; /* 2???????????¢????¨????????????¢??° */ double calc_distance(point p1, point p2); int main(void) { point pnt1, pnt2; pnt1.x = 0.0; pnt1.y = 0.0; pnt2.x = 0.0; pnt2.y ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250066/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250066/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.coordinate_value = ...
#include <math.h> #include <stdio.h> int main() { double x_1,y_1,x_2,y_2; scanf("%lf%lf%lf%lf",&x_1,&y_1,&x_2,&y_2); printf("%lf\n",sqrt(pow(x_1-x_2,2)+pow(y_1-y_2,2))); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250109/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250109/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> int main(void){ double x1,y1,x2,y2; scanf("%lf %lf %lf %lf",&x1,&y1,&x2,&y2); printf("%lf\n",hypot(x1-x2,y1-y2)); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250202/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250202/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> int main(){ double x1, y1, x2, y2, distance; scanf("%lf %lf %lf %lf", &x1, &y1, &x2, &y2); distance=sqrt((pow(x2-x1, 2)+pow(y2-y1, 2))); printf("%f\n", distance); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250246/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250246/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> int main() { double x1, x2, y1, y2; double dst; scanf("%lf %lf %lf %lf", &x1, &y1, &x2, &y2); dst = (x2-x1)*(x2-x1)+(y2-y1)*(y2-y1); dst = sqrt(dst); printf("%f\n", dst); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250297/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250297/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 gcd(int a, int b) { if (b == 0) return a; return gcd(b, a % b); } int main(void) { int n,m,k; scanf("%d %d %d",&n,&m,&k); long long int mod=998244353; n--; long long int ans=1; int z=k; int a[z+5]; if(2*z>n) { z=n-z; } for (int i = 0; i < z; ++i) { a[i]=n-i; } for (in...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_25034/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_25034/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<math.h> #include<stdlib.h> int main(){ double x1=0.0, y1=0.0, x2=0.0, y2=0.0; double ans=0.0; double X,Y; scanf("%lf %lf %lf %lf",&x1, &y1, &x2, &y2); X = x1-x2; if(X<0) X*=-1.0; Y = y1-y2; if(Y<0) Y*=-1.0; ans = sqrt(X*X + Y*Y); printf("...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250383/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250383/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<math.h> #include<stdio.h> int main(void) { double x1,y1,x2,y2,d; scanf("%lf %lf %lf %lf", &x1,&y1,&x2,&y2); d = sqrt((x2 - x1)*(x2 - x1) + (y2 - y1)*(y2 - y1)); printf("%f\n", d); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250426/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250426/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 ans,a; scanf("%d",&a); if(a<3) ans=a; else ans=1; printf("%d\n",ans); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_25047/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_25047/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 V; scanf("%d", &V); if(V == 2) printf("2\n"); else printf("1\n"); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_25052/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_25052/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 l[100], v[100], i, lon; double M, L, t, V; while ( (scanf("%d,%d,%d,%d,%d,%d,%d,%d,%d,%d,%d,%d", &l[1], &l[2], &l[3], &l[4], &l[5], &l[6], &l[7], &l[8], &l[9], &l[10], &v[1], &v[2])) != EOF ){ L = 0; for ( i = 1; i < 11; i++ ) { L += l[i]; } ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250563/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250563/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 rail[10], a, b, i, sum, s; int main(){ while(1){ sum = 0; for(i = 0;i < 10;i++){ scanf("%d,", rail + i); sum += rail[i]; } if(scanf("%d,%d", &a, &b) == EOF)return 0; s = 0; for(i = 0;i < 10;i++){ s += rail[i]; if(s * b >= (sum - s) * a){ printf(...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250613/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250613/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" @sum = dso_local local_unna...
#include <stdio.h> int main(){ int n, tmp=0, cnt[10000+1]={0}; scanf("%d", &n); for(int x=1; x<=100; x++){ for(int y=1; y<=100; y++){ for(int z=1; z<=100; z++){ tmp = x*x + y*y + z*z + x*y + y*z + z*x; if( tmp <= 10000 ){ cnt[tmp]++; } } } } for(int i=1; i<=n; i++){ printf(...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250657/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250657/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 datanum = 0; int x = 0; int y = 0; int z = 0; int n = 0; int i = 0; int count = 0; scanf("%d", &datanum); for (i = 1; i <= datanum; i++) { count = 0; for (x = 1; x < 99; x++) { for (y = 1; y < 99; y++) { ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250714/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250714/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,k,m,b,r,p,q,boat[51],f[51]={0},ans=0,i,j; scanf("%d %d",&n,&k); for(i=0;i<k;i++){ scanf("%d",&m); for(j=0;j<m;j++){ scanf("%d",&b); boat[b]=i; } } scanf("%d",&r); for(i=0;i<r;i++){ scanf("%d %d",&p,&q); if(boat[p]==boat[q]){ f[p]...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250800/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250800/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, sum, i; while (scanf("%d", &a) != EOF){ scanf("%d", &b); sum = a + b; i = 0; while (1){ sum /= 10; i++; if (sum == 0){ break; } } printf("%d\n", i); } return (0); }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250844/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250844/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 alg ( int a, int b ) { int src = a + b; int result = 0; do { result++; } while ( (src /= 10) != 0 ); return result; } int main ( void ) { int a, b; ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250888/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250888/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 keta(int num){ int cnt = 0; while( num > 0){ num /= 10; cnt++; } return cnt; } int main(void){ int a; int b; while( scanf("%d %d",&a ,&b) != EOF){ printf("%d\n",keta(a + b)); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250930/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250930/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, x, p; while(scanf("%d %d", &a, &b) != EOF){ p = 1; x = a + b; while(x >= 10){ x /= 10; p++; } printf("%d\n", p); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250974/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250974/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, sum, i; while(scanf("%d%d", &a, &b) != EOF) { sum = a + b; for(i=0;sum!=0;i++) { sum /= 10; } printf("%d\n", i); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_251016/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_251016/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,i; while(scanf("%d%d",&a,&b) != EOF){ c = a + b; if(c < 10)printf("1\n"); else if(10 <= c && c < 100)printf("2\n"); else if(100 <= c && c < 1000)printf("3\n"); else if(1000 <= c && c < 10000)printf("4\n"); else if(10000 <= c && c < 100000)printf("5\n"); else if(100000 <= c && c...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_251067/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_251067/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 n,k,ans1,ans2,maxi=-5; char s[105][105]; int min(int x, int y) { if(x>y) return y; return x; } int main() { scanf("%d%d",&n,&k); for(int i=1;i<=n;i++) scanf("%s",s[i]+1); for(int i=1;i<=n;i++) for(int j=1;j<=n;j++) if(s[i][j]=='.') { int up,down,...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_25111/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_25111/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" @maxi = dso_local local_unnam...
#include<stdio.h> int main() { int a, b, sum, p; while (scanf("%d %d", &a, &b)!= EOF) { p = 0; sum = a + b; while (sum != 0) { sum =sum/ 10; p++; } printf("%d\n", p); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_251153/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_251153/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){ // Here your code ! unsigned int a,b; unsigned int work; unsigned int cnt=0; int i; for(i=0;i<200;i++){ cnt=1; if(scanf("%d %d",&a,&b) == EOF) break; work = (a+b)/10; while(work){ cnt++; work = work/10; ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_251203/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_251203/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> typedef struct{ int a; int b; }SET; /* ????????????????????£?¨? */ int count_digits(int value); /* main??¢??° */ int main(void){ SET set[200]; int set_cnt, digits; int i; for(set_cnt = 0;set_cnt < 200;set_cnt++) if(scanf("%d %d", &(set[set_cnt].a), &(set[set_cnt].b)) == EOF)break; for(i ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_251254/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_251254/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.SET = type { i32, i...
#include<stdio.h> int main() { unsigned long long int a,b,sum; while(scanf("%llu %llu",&a,&b)!=EOF) { int cnt=0; sum=a+b; while(sum!=0){ sum=sum/10; cnt++; } printf("%d\n",cnt); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_251298/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_251298/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; int b; int c; int i; int k; i = 0; while (scanf("%d%d", &a,&b) != EOF) { c = a + b; k = 1; while ((c / 10) != 0 ) { c = c / 10; k++; } printf("%d\n", k); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_251384/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_251384/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,n,m; for(;;){ if(scanf("%d",&a)==EOF){break;} scanf("%d",&b); n=a+b; m=1; while(n>=10){ n=n/10; m++; } printf("%d\n",m); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_251456/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_251456/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...
//non-decreasing 不减!增加或维持! //感觉是寻找两个数组的不同项! /*interface*/ /*interface implementation*/ /*client*/ #include<stdio.h> int main() { int na,nb; scanf("%d%d",&na,&nb); int k,m; scanf("%d%d",&k,&m); int i; int ak=0; for(i=0;i<na;i++) { int a; scanf("%d",&a); if(i==k-1) { ak=a; } } int bm=0; for(i=0;i<nb;...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_2515/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_2515/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 k,n,s,p; scanf("%d%d%d%d",&k,&n,&s,&p); if(n%s==0) s=n/s; else s=n/s+1; s=s*k; if(s%p==0) p=s/p; else p=s/p+1; printf("%d",p); }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_25155/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_25155/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<math.h> int main() { int i,j,k ,l,s,p,m,n; scanf("%d%d%d%d",&k,&n,&s,&p); if(n%s!=0) l=(n/s)+1; else l=n/s; m=l* k; if(m%p!=0) j=(m/p)+1; else j=m/p; printf("%d\n",j); }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_25160/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_25160/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 a=0, b=0; char ch; int total; int count; while( (ch=fgetc(stdin)) != EOF ){ a = ch - '0'; while( (ch=fgetc(stdin)) != ' ' ){ a = 10*a + ch - '0'; } while( (ch=fgetc(stdin)) != '\n' ){ b = 10*b + ch - '0'; } total...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_251643/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_251643/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> int digit( int n ) { int count = 1; while ( n / 10 != 0 ) { n /= 10; count++; } return count; } int main( void ) { int a, b; while ( scanf( "%d %d", &a, &b ) != EOF ) { printf( "%d\n", digit( a + b ) ); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_251694/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_251694/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() { int a, b; while(scanf("%d %d", &a, &b) != EOF){ char s[255]; int c = a + b; sprintf(s, "%d", c); int length = strlen(s); printf("%d\n", length); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_251737/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_251737/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 digit(int x) { int i; for(i=1;x/=10;i++) ; return i; } int main() { int a,b; while(scanf("%d %d",&a,&b) != EOF) printf("%d\n",digit(a+b)); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_251780/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_251780/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...
//2020.1.21 //s1270188 xxxmk2 //v0_02 #include<stdio.h> int main(){ int a, b; while(1){ if(scanf("%d %d",&a,&b)==EOF) break;; a+=b; for(b=0;a!=0;b++) a/=10; printf("%d\n",b); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_251830/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_251830/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> #define LEN 100005 typedef struct pp { char name[100]; int t; } P; P Q[LEN]; int head, tail, n; void enqueue(P x){ Q[tail] = x; tail = (tail + 1) % LEN; } P dequeue(){ P x = Q[head]; head = (head + 1) % LEN; return x; } int min(int a, int b) { return a < b ? a :...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_251874/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_251874/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 { [100 x ...
#include<stdio.h> #include<string.h> struct queues { char name[11]; int time; int next; }; int main( void ) { struct queues ps[100001]; int i; int n,q; int cnt,cur,pre; int time,res; int head; scanf( "%d%d", &n, &q ); head=0; for( i=0; i<n; i++ ) { scanf( "%s%d", ps[i].name, &ps[i].time ); ps[i].n...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_251924/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_251924/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.queues = type { [11...
#include<stdio.h> #include<string.h> typedef struct { char name[100]; int t; }Queue; Queue Q[100000]; int n, head = 0, tail = 0; void enqueue(Queue); Queue dequeue(void); int main(){ int i, q, count = 0, time = 0; Queue cell; scanf("%d %d",&n,&q); for (i = 1; i <= n; i++){ scanf("%s",Q[i].na...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_251975/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_251975/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.Queue = type { [100...
#include<stdio.h> #include<string.h> #define LEN 1000050 typedef struct pp{ char name[100]; int t; }P; P Q[LEN+1]; int head,tail,num,q; void enqueue(P); P dequeue(void); /*main??¢??°*/ int main(){ int elaps = 0; int i, q; P proce; /*??\???*/ scanf("%d %d", &num, &q); for ( i = 1; i <= num ; i++)...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_252031/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_252031/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 { [100 x ...
#include<stdio.h> #include<string.h> #define LEN 1000005 typedef struct pp{ char name[100]; int t; }P; P Q[LEN+1]; int head, tail, n; void enqueue(P); P dequeue(); int main(){ int elaps = 0, c = 0; int i, q; P u; scanf("%d %d", &n, &q); for ( i = 1; i <= n; i++){ scanf("%s", Q[i].name); ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_252075/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_252075/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 { [100 x ...
#include<stdio.h> #define N 100000 typedef struct{ char n[10]; int q; }Data; int main(){ int n,q,i,j,head=0,tail,sum=0; Data data[N]; scanf("%d%d",&n,&q); for(i=0;i<n;i++){ scanf("%s%d",&data[i].n,&data[i].q); } head=0; tail=n; while(1){ data[head].q-=q; sum+=q; if(data[h...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_252118/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_252118/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.Data = type { [10 x...
#include<stdio.h> #include<string.h> typedef struct { char name[100]; int t; } process; process array[100001]; int head=0,tail=0; int main(void){ int n,q,i,sum=0,endprocess=0; scanf("%d %d",&n,&q); for(i=0;i<n;i++){ scanf("%s %d",array[i].name,&array[i].t); } while(endprocess!=n){ if(q<array[head].t){ ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_252161/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_252161/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.process = type { [1...
#include <stdio.h> #define MAX 100000 typedef struct Q{ char name[10]; int time; int sum; }Q; void enqueue(Q); Q dequeue(); int head=0; int tail=0; Q data[MAX]; int main(){ int n,q; Q x; int i,all=0; scanf("%d%d",&n,&q); for(i=0;i<n;i++){ scanf("%s%d",x.name,&x.time); ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_252204/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_252204/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.Q = type { [10 x i8...
#include <stdio.h> #include <string.h> #define LEN 100005 typedef struct p { char name[100]; int t; } P; P Q[LEN + 1]; int head, tail, n; void enqueue(P x) { Q[tail] = x; if ((tail) == (LEN)) { tail = 1; } else { tail++; } } P dequeue() { P x = Q[head]; if ((head) == (LEN)) { head = 1; } else { ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_252255/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_252255/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.p = type { [100 x i...
#include<stdio.h> #include<time.h> #define MAX 100005 typedef struct tq{ char name[100]; int time; } s; int head, tail, n; s Q[MAX]; s dequeue() { s t; t = Q[head]; head = (head + 1) % MAX; return t; } void enqueue(s x) { Q[tail] = x; tail = (tail + 1) % MAX; } int main() {...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_252299/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_252299/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.tq = type { [100 x ...
#include<stdio.h> #define MAX_LEN 100000 typedef struct { char name[11]; int val; } dic; dic arr[MAX_LEN]; int head, tail; int enqueue(dic x){ if(tail+1 == head){ printf("OverFlow\n"); return 0; } arr[tail] = x; if(tail+1 == MAX_LEN){ tail=0; }else{ tail++;...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_252349/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_252349/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.dic = type { [11 x ...
#include <stdio.h> #include <stdlib.h> #include <stdbool.h> #define SIZE 100001 typedef struct { char name[10]; int time; } process; typedef struct { int head,tail,count,size; process *data; } Queue; process nullp = {"", 0}; bool isFull(Queue *que); bool enqueue(Queue *que, process p); bool isEmpty(Queue *que);...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_252392/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_252392/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.process = type { [1...
#include <stdio.h> // プロセスを表す構造体 typedef struct pp { char name[100]; int t; } P; P Q[100000]; int head, tail, n, q, c; void enqueue(P x) { Q[tail] = x; if (tail == n) { tail = 0; } else { tail++; } } P dequeue() { P x = Q[head]; if (head == n) { head = 0; } else { head++; } ret...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_252435/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_252435/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 { [100 x ...
#include<stdio.h> #include<stdlib.h> typedef struct { char num[11]; int time; } Data; typedef struct { Data data; Data *bef_p, *aft_p; } Process; int main(void){ int n, last, total = 0, q, i, cnt = 0; Process *p_arr, *po, *bef, *aft; scanf("%d %d\n", &n, &q); last = n-1; p_arr = (Process*)malloc(sizeof(Pro...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_252479/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_252479/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.Process = type { %s...
#include<stdio.h> #include<stdlib.h> typedef struct { char name[11]; int time; int flag; }Process; Process *Q; int head; int tail; int n; Process dequeue(); void enqueue(Process); int main() { int ms; int i; Process deq; int run = 0; scanf("%d%d", &n, &ms); head = 0; tail = 0; n++; Q = (Process *)mal...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_252529/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_252529/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.Process = type { [1...
#include<stdio.h> #define L 100005 typedef struct{ char pname[100]; int time; }EQ; EQ eq[L]; int head, tail,n; void enqueue(EQ a){ eq[tail]=a; tail=(tail+1)%L; } EQ dequeue(){ EQ a=eq[head]; head=(head+1)%L; return a; } int minjudge(int a,int b){ if(a<b){return a;} else{return b;} } int main(){ ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_252572/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_252572/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.EQ = type { [100 x ...
#include<stdio.h> #include<string.h> #define MAX 1000005 typedef struct d{ char name[11]; int time; char sname[11]; int stime; char Ansname[11]; int Anstime; }date; date tn[MAX]; int main(){ int n,q,i,str,tmp,tmp2,j,k=0; scanf("%d%d",&n,&q); for(i=1;i<n+1;i++){ scanf("%s ",tn[i].name); ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_252615/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_252615/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.d = type { [11 x i8...
#include<stdio.h> #include<string.h> #define LEN 100005 typedef struct pp{ char name[100]; int t; }P; P Q[LEN]; int head, tail, n; void enqueue(P x){ Q[tail] = x; tail = (tail + 1) % LEN; } P dequeue(){ P x = Q[head]; head = (head + 1) % LEN; return x; } int min(int a, int b){ return a<b ? a : b;} int main...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_252666/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_252666/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 { [100 x ...
#include<stdio.h> #include<string.h> #define LEN 100005 typedef struct pp{ char name[100]; int t; }P; P Q[LEN+1]; int head, tail, n; void enqueue(P x){ Q[tail]=x; if(tail+1==LEN) tail=0; else tail=tail+1; } P dequeue(){ P x; x=Q[head]; if(head+1==LEN) head=0; else head=head+1; return x; } int m...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_252716/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_252716/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 { [100 x ...
#include<stdio.h> int main() { int n,i; double k,lob,hor,ans; scanf("%d %lf",&n,&k); double arr[n],sum=0; for(i=0;i<n;i++) { scanf("%lf",&arr[i]); sum+=arr[i]; } for(i=0;i>=0;i++) { if((sum+(i*k))/(n+i)>=k-.5) { ans=i; break; ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_25276/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_25276/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 <string.h> #define LEN 100005 typedef struct pp { char name[100]; int t; } P; P Q[LEN]; int head, tail, n; void enqueue(P x) { Q[tail] = x; tail = (tail + 1) % LEN; } P dequeue() { P x = Q[head]; head = (head + 1) % LEN; return x; } int min(int a,int b) { return a <...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_252802/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_252802/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 { [100 x ...
#include<stdio.h> #include<stdlib.h> #define len 100005 typedef struct pp{ char name[100]; int t; }p; p q[len]; int head,tail,n; void enqueue(p x){ q[tail]=x; tail=(tail+1)%len; } p dequeue(){ p x=q[head]; head=(head+1)%len; return x; } int min(int a,int b){ return a<b?a:b; } int main(){ int elaps=0,c; int i,...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_252846/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_252846/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 { [100 x ...
#include <stdio.h> int main() { float n, k; float ara[100]; scanf("%f%f", &n, &k); int i; for(i = 0; i < n; i++) { scanf("%f", &ara[i]); } float sum = 0; for(i = 0; i < n; i++) { sum = sum + ara[i]; } float average; average = sum / n; if((k * 10 - avera...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_25289/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_25289/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<string.h> #define LEN 100005 typedef struct pp{ char name[100]; int t; } P; P Q[LEN]; int head,tail,n; void enqueue(P x){ Q[tail] = x; tail = (tail + 1) % LEN; } P dequeue(){ P x = Q[head]; head = (head + 1) % LEN; return x; } int min(int a,int b){ return a < b ? a...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_252932/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_252932/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 { [100 x ...
#include <stdio.h> #include <stdlib.h> #define LEN 100005 typedef struct pp{ char name[100]; int t; }P; P Q[LEN+1]; int head=0,tail=0,n; void enqueue(P x){ Q[tail]=x; tail=(tail+1)%LEN; } P dequeue(void){ P x=Q[head]; head=(head+1)%LEN; return x; } int min(int a, int b){ return a<b ? a:b; } int ma...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_252976/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_252976/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 { [100 x ...
#include<stdio.h> #define LEN 100005 typedef struct pp{ char name[100]; int t; }P; P Q[LEN]; int head=0, tail=0, n; void enqueue(P); P dequeue(void); void enqueue(P x){ Q[tail++] = x; if(tail == LEN) tail=0; } P dequeue(){ if(head == LEN) head=0; return Q[head++]; } int main(){ int i, q,dif,q_sum=0...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_253018/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_253018/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 { [100 x ...
#include <stdio.h> #include <stdlib.h> #define LEN 100005 typedef struct pp{ char name[100]; int t; }P; P Q[LEN+1]; int head, tail, n; void enqueue(P x){ Q[tail]=x; if(tail+1 >= LEN+1) tail=0; else Q[tail++]=x; } P dequeue(){ P x=Q[head]; if(head+1 >= LEN+1) head=0; else head++; retu...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_253069/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_253069/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 { [100 x ...
#include <stdio.h> #include <string.h> #define LEN 100005 typedef struct pp{ char name[100]; int t; }P; P Q[LEN]; int head , tail , n; void enqueue(P x){ Q[tail] = x; tail = (tail + 1) % LEN; } P dequeue() { P x = Q[head]; head = (head+1) % LEN; return x; } int min(int a, int b){ return a < b ? a : b;} int...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_253111/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_253111/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 { [100 x ...
#include <stdio.h> #include <math.h> #include <ctype.h> #include <string.h> #include <stdbool.h> #define MAX 100001 int n, head = 0, tail = 0; typedef struct pp{ char name[11]; int time; }P; P Q[MAX + 1]; bool isEmpty(){ return head == tail; } bool isFull(){ return head == (tail +1) % MAX; } void enqueue(P x...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_253155/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_253155/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 { [11 x i...
#include <stdio.h> #define LEN 100005 struct process { char name[100]; int ntime; }; struct process A[LEN]; int head,tail; void enqueue(struct process x) { A[tail] = x; tail = (tail + 1) % LEN; } struct process dequeue() { struct process x = A[head]; head = (head + 1) % LEN; return x; } ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_253199/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_253199/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.process = type { [1...
//ラウンドロビンスケジューリング //2018-12-17 //Ebitani Akira #include<stdio.h> #include<string.h> #define LEN 100005 typedef struct pp{ char name[100]; int t; }P; P Q[LEN+1]; int head, tail, n; void enqueue(P x){ Q[tail] = x; tail = ( tail + 1 ) % LEN; } P dequeue(){ P x = Q[head]; head = ( head + 1 ) % LEN; r...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_253241/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_253241/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 { [100 x ...
#include<stdio.h> #include<stdlib.h> #define LEN 100005 typedef struct pp{ char name[100]; int t; }P; P Q[LEN]; int head, tail, n; void enqueue(P x){ Q[tail]=x; if(tail+1==n){ tail=0; } else{ tail++; } } P dequeue(){ P x; x=Q[head]; if(head+1==n){ head=0; ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_253285/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_253285/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 { [100 x ...
#include<stdio.h> #include<string.h> #define LEN 100005 typedef struct pp{ char name[100]; int t; }P; P Q[LEN+1]; int head, tail, n; void enqueue(P x){ Q[tail] = x; tail = (tail + 1)%LEN; } P dequeue(){ P x = Q[head]; head = (head + 1)%LEN; return x; } int min(int a,int b){ return a < b ? a :b; }...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_253328/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_253328/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 { [100 x ...
#include<stdio.h> typedef struct p{ char name[10]; int time; }p; void enqueue(p a); p dequeue(); p s[100005]; int head = 0; int tail = 0; int n; int limit; int total; int main() { scanf("%d", &n); scanf("%d", &limit); for(int i = 0; i < n; i++) scanf("%s %d",s[i].name,&s[i].time); for(int i = 0; i < n; i++) ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_253371/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_253371/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.p = type { [10 x i8...
#include<stdio.h> int x[125000],min=150000; int main(void) { int n,m,i,j,k,l,wcnt,bcnt,rcnt,cnt=0; char a[50][51]; scanf("%d %d",&n,&m); for(i=0;i<n;i++){ x[i]=0; } for(i=0;i<n;i++){ scanf("%s",a[i]); } for(i=0;i<n-2;i++){ for(j=i+1;j<n-1;j++){ for(k=0;k<=i;k++){ wcnt=0; for(l=0;l<m;l++){ ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_253414/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_253414/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" @min = dso_local local_unna...
#include <stdio.h> #include <string.h> #include <math.h> #include <stdlib.h> #include <limits.h> #include <stdbool.h> #define rep(i, n) for(int i=0; i<(n); ++i) #define max 200001 //qsort(str, n, sizeof(int), up_comp); int up_comp(const void *a, const void *b){return *(int*)a - *(int*)b;} int down_comp(const void *a...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_253458/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_253458/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> #define _FOREVER 1 int main(void) { int N,i,len; char S[10000+1]; scanf("%d ",&N); scanf("%s",S); len=strlen(S); for(i=0;i<len;i++) { S[i]+=(char)N; printf("%c",S[i]>'Z'?S[i]-26:S[i]); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_253515/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_253515/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; char s[10001]; scanf("%d%s", &n, s); for (int i = 0; s[i] != '\0'; i++) { if ((s[i] += n) > 'Z') s[i] -= 26; } puts(s); }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_253559/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_253559/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; char c; scanf("%d\n", &n); while ((c = getchar()) != '\n') { putchar((c + n - 'A') % 26 + 'A'); } }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_253601/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_253601/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> int main(){ int n; scanf("%d",&n); char s[n]; int i,count0=0,count1=0,flag=0,count=0; scanf("%s",s); for(i=0;i<n;i++){ if(s[i]=='0') count0++; else count1++; } if(count0!=count1){ printf("1\n"); if((count...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_25366/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_25366/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<string.h> int main(){ int one = 0; int zero = 0; int n; scanf("%d",&n); char s[n]; scanf("%s",s); for(int i=0;i<n;i++) {if(s[i]=='1') one++; else zero++; } if(zero==one) { printf("2\n"); int k = n-1; int one1=0; int zero1=0; int one2=0; int zero2=0...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_25371/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_25371/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; char S[37564]; int i; if (scanf("%d", &N) != 1) return 1; if (scanf("%37567s", S) != 1) return 1; for (i = 0; S[i] != '\0'; i++) { putchar('A' + (S[i] - 'A' + N) % 26); } putchar('\n'); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_253753/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_253753/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...
// AtCoder165 C #define _CRT_SECURE_NO_WARNINGS #include <stdio.h> #include <math.h> #include <assert.h> #include <string.h> #include <memory.h> #include <malloc.h> #include <stdlib.h> // qsortで用いる比較用関数.*a<*bならaが先になる. int compare(const void* a, const void* b) { return *(int*)a - *(int*)b; } int main() { int ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_253810/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_253810/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,M,C,i,j,ans=0,check=0; scanf("%d %d %d",&N,&M,&C); int B[M]; for(i=0;i<M;i++){ scanf("%d",&B[i]); } int A[N][M]; for(i=0;i<N;i++){ for(j=0;j<M;j++){ scanf("%d",&A[i][j]); } } for(i=0;i<N;i++){ check=0; for(j=0;j<M;j++){ check=...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_253854/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_253854/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; int aa[110],bb[110]; int ans = 0; int i,j; int sums; scanf("%d %d %d", &a,&b,&c); for(i=0; i<b; i++){ scanf("%d", &bb[i]); } for(j=0; j<a; j++){ sums = c; for(i=0; i<b; i++){ scanf("%d", &aa[i]); ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_253898/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_253898/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,j,k,l,N, M, A[50][50],B[50],C,sum,count=0; scanf("%d %d %d", &N, &M, &C); sum = C; for (i = 1; i <= M; i++) scanf("%d", &B[i]); for (i = 1; i <= N; i++) { for (j = 1; j <= M; j++) scanf("%d", &A[i][j]); } for (k = 1; k <= N; k++) { for (l = 1; l <= M; l++) { s...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_253940/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_253940/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> int main(void) { int ar[100][100]; char *ptr; int z,i,j,count; char str[100]={'\0'}; char *ln; fgets(str, 100, stdin); // 入力:"123456\n" ln = strchr(str, '\n'); /* 改行文字を検索 */ if (ln != NULL) { /* 改行が読み取られていたかどうか */ *ln = '\0'; /* 改行文字を終端文字に置き換える */ } el...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_253991/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_253991/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> int main(){ int n,m,c,i,j,tot=0; long long sum=0; scanf("%d%d%d",&n,&m,&c); int b[m]; for(i=0;i<m;++i) scanf("%d",&b[i]); int a[m]; for(i=0;i<n;++i){ for(j=0;j<m;++j) scanf("%d",&a[j]); for(j=0;j<m;++j) sum+=a[j]*b[j]; if(sum+c>0) ++tot; sum=0; } printf("%d",tot); return 0...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_254033/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_254033/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...