Source_Code
stringlengths
69
484k
IR_Original
stringlengths
2.05k
17.9M
#include<stdio.h> int main(void){ int i,j,k,n,b,f,r,v,data[4][3][10]={0}; scanf("%d\n",&n); for(i=0;i < n;i++){ scanf("%d %d %d %d\n",&b ,&f ,&r ,&v); data[b-1][f-1][r-1] += v; } for(i=0;i < 4;i++){ for(j=0;j < 3;j++){ for(k=0;k < 10;k++){ printf(" %d",data[i][j][k]); if (k == 9){ printf("\n"); } } if (j == 2 && i != 3...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_236459/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_236459/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 room[4][3][10]={0}; int n,b,f,r,v; int i,j,k; scanf("%d",&n); for(i=1;i<=n;i++){ scanf("%d%d%d%d",&b,&f,&r,&v); room[b-1][f-1][r-1]+=v; } for(i=0;i<=3;i++){ for(j=0;j<=2;j++){ for(k=0;k<=9;k++){ printf(...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_236501/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_236501/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, b, f, r, v; int i, j, k; int A[4][3][10] = {0}; scanf("%d", &n); for(i=0; i<n; i++) { scanf("%d %d %d %d", &b, &f, &r, &v); A[b-1][f-1][r-1] += v; } for(i=0; i<4; i++) { if(i != 0) printf("####################\n"); for(j=0; j<3; j++) { for(k=0; k<10; k++) { ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_236545/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_236545/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, b, f, r, v; int cou1, cou2, cou3, cou4; int da [4] [3] [10]; for(cou1 = 0; cou1 < 4; cou1++){ for(cou2 = 0; cou2 < 3; cou2++){ for(cou3 = 0; cou3 < 10; cou3++){ da [cou1] [cou2] [cou3] = 0; } } } scanf("%d", &n); for(cou1 = 0; cou1 < n; cou1++){ scan...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_236589/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_236589/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 room[4][3][10] = {0}; int n, b, f, r, v, i, j, k; scanf("%d\n", &n); for (i = 0; i < n; i++) { scanf("%d %d %d %d", &b, &f, &r, &v); room[b - 1][f - 1][r - 1] += v; } for (b = 0; b < 4; b++) { for (f = 0; f < 3; f++) { for (r = 0; r < 10; r++) { printf(" %d"...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_236639/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_236639/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> double max(double a, double b) { return a > b ? a : b; } int main() { double a, b, c, d; double max1, max2; scanf("%lf%lf%lf%lf", &a, &b, &c, &d); max1 = max(3.0 * a / 10.0, a - a / 250.0 * c); max2 = max(3.0 * b / 10.0, b - b / 250.0 * d); if(max1 > max2...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_23669/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_23669/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 count[4][3][10] = {}; int N, i, j, k; scanf("%d", &N); for (i = 0; i < N; i++) { int b, f, r, v; scanf("%d %d %d %d", &b, &f, &r, &v); count[b - 1][f - 1][r - 1] += v; } for (i = 0; i < 4; i++) { if (i > 0) printf("####################\n"); for (j = 0;...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_236732/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_236732/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 building1[3][10] = { 0 }, building2[3][10] = { 0 }, building3[3][10] = { 0 }, building4[3][10] = { 0 }; int n,b,f,r,v,i,j; scanf("%d", &n); for (i = 0; i < n; i++) { scanf("%d %d %d %d", &b, &f, &r, &v); if (b == 1) { building1[f - 1][r - 1] += v; } if (b == 2) ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_236776/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_236776/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...
//====================================================================== // Contents : AOJ ITP1_6_C // 公舎の入居・退去の情報を読み込み、各部屋の入居者数を出力 // 1フロア10部屋、3階建ての公舎が4棟存在 // Input : 情報の数 n // 棟        building (1 ≦ b ≦ 4) // 階数       floor (1 ≦ f ≦ 3) // ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_236848/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_236848/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,b,f,r,v,count[4][3][10] ={0}; char gara; scanf("%d",&n); for(i=0;i<n;i++){ scanf("%d %d %d %d",&b,&f,&r,&v); count[b-1][f-1][r-1]+=v; } for(i=0;i<4;i++){ for(j=0;j<3;j++){ for(k=0;k<10;k++){ printf(" %d",count[i][j][k]); } printf("\n"); ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_236891/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_236891/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,j,k,b,f,r,v; int house[4][3][10]={0}; scanf("%d",&n); for(i =0; i <n; i++) { scanf("%d %d %d %d",&b,&f,&r,&v); house[b-1][f-1][r-1] += v; } for(k=0; k<4; k++) { for(j=0; j<3; j++) { for(i=0; i<10;i++) { printf(" %d",house[k][j][i]); } ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_236934/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_236934/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> void print_info(int array[][10]); int main (void) { int input,b,f,r,v; int A[3][10],B[3][10],C[3][10],D[3][10]; int i,j; for(i = 0 ; i < 3 ; i++) { for(j = 0 ; j < 10 ; j++) { A[i][j] = 0; B[i][j] = 0; C[i][j] = 0; D[i][j] = 0; } } scanf("%d",&input); for...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_236978/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_236978/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 MAX 100 int main(){ char teams[MAX][10]; int goals[MAX], max, i, j, n, index; char team[10]; memset(goals, 0, MAX*sizeof(int)); scanf("%d", &n); for(i=0; i < n; i++){ scanf("%s", &team); for(j=0; j < i; j++) if(!strcmp(t...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_23702/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_23702/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 b,f,r,v,n,i,j,k; int X[5][5][20]={0}; scanf("%d",&n); for(i=0;i<n;i++) { scanf("%d %d %d %d",&b,&f,&r,&v); X[b-1][f-1][r-1]+=v; } for(i=0;i<4;i++) { for(j=0;j<3;j++) { for(k=0;k<10;k++) { printf(" %d",X[i][j][k]); } printf("\n"); } if(i<3) printf(...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_237063/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_237063/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, b, f, r, v; int nor[4][3][10]={}; int i, j, k; scanf("%d", &n); for(i=0;i<n;i++){ scanf("%d %d %d %d", &b, &f, &r, &v); nor[b-1][f-1][r-1]+=v; } for(i=0;i<4;i++){ for(j=0;j<3;j++){ for(k=0;k<10;k++){ printf(" %d", nor[i][j][k]); ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_237106/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_237106/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,flag=0; long long i=0; scanf("%d ",&n); while(i*1234567<=n) { long long j=0; while(i*1234567+j*123456<=n) { if((n-i*1234567-j*123456)%1234==0) flag=1; j++; } i++; } if(flag) printf("YES\n"); else printf("NO\n"); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_23715/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_23715/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 k,c,i,total,kai,t; for(t=0; t<100; t++){ scanf("%d",&k); if(k ==0 ) break; total=0; for(i=0; i<(k*k-k)/2; i++){ scanf("%d",&c); total+=c; } kai=total/(k-1); printf("%d\n",kai); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_237207/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_237207/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> long keisan(long x, long y, char z){ long ans; if(z=='+') ans=x+y; else if(z=='-') ans=x-y; else if(z=='*') ans=x*y; else if(z=='/') ans=x/y; return ans; } int main(void){ long a, b, result; char num[10], c; scanf("%ld", &a); scanf(" %c", &c); scanf(" %ld", &b); result = keisan(a,...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_237265/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_237265/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 MAX 10000 #define NIL -1 typedef struct N { int parent, left, right; } Node; Node T[MAX]; int n, D[MAX], H[MAX]; void setDepth(int u, int d){ if( u == NIL ) return; D[u] = d; setDepth( T[u].left, d+1); setDepth( T[u].right, d+1); } int setHeight(int u){ int h1 = 0, h2 = 0; if...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_237315/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_237315/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.N = type { i32, i32...
#include<stdio.h> #define MAX 100005 #define NIL -1 struct Node{ int p, l, r; }; struct Node T[MAX]; int n, D[MAX], H[MAX]; void setDepth(int u, int d){ if(u == NIL) return; D[u] = d; setDepth(T[u].l, d+1); setDepth(T[u].r, d+1); } int setHeight(int u){ int h1=0, h2=0; if(T[u].l != NIL...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_237359/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_237359/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 = type { i32, ...
#include<stdio.h> #include<stdlib.h> #include<string.h> #include<math.h> #include<limits.h> #define lpton(i,n) for(int i=0;i<(int)n;i++) #define lpto0(i,n) for(int i=n;i>-1;i--) #define lpmn(i,m,n) for(i=m;i<n;i++) #define ms0(l) memset(l,0,sizeof(l)) #define ms(l,n,s) memset(l,n,s) #define m(x,n) (x*)malloc(n*sizeof(x...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_237409/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_237409/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.tree = type { i32, ...
#include <stdio.h> #include <string.h> #include <stdlib.h> struct Node { int key; struct Node* parent; struct Node* left; struct Node* right; struct Node* sibling; int degree; int depth; int height; char type[15]; }; typedef struct Node * NodePointer; void serach_depth (NodePointer ,int ); int main (){ i...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_237452/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_237452/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 = type { i32, ...
#include <stdio.h> int main() { long int n; scanf("%ld", &n); int flag = 0; for(long int i = n / 1234567; i >= 0; i--){ for(long int j = (n - 1234567 * i) / 123456; j >= 0; j--){ if ((n - (1234567 * i + 123456 * j)) % 1234 == 0) flag = 1; } } if(flag) printf("YES"); ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_23751/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_23751/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> #define MAX 100000 int getDepth(int); int getSibling(int); int getHeight(int); struct nibunki { int parent; int left; int right; }; struct nibunki array[MAX]; int height[MAX]; int main(){ int n, i, id, degree, left, right, root; scanf("%d", &n); for( i=0; i<n; i++){ array[i].p...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_237568/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_237568/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.nibunki = type { i3...
#include<stdio.h> #define NIL -1 struct Node{ int left; int right; int parent; }; int sibling(int); int children(int); int depth(int); int height(int); void judge(int); struct Node inputNodedata[10000]; int main(){ int sumNode,Nodeid,i,j,leftdata,rightdata; scanf("%d",&sumNode); for(i =...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_237618/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_237618/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 = type { i32, ...
#include <stdio.h> #define N 10000 typedef struct{ int p,l,r; }Node; Node T[N]; int n, D[N], H[N]; void setDepth(int u, int d){ if(u == -1) return; D[u] = d; setDepth(T[u].l, d+1); setDepth(T[u].r, d+1); } int setHeight(int u){ int h1=0, h2=0; if(T[u].l != -1) h1 = setHeight(T[u].l) + 1; if(T[u]...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_237661/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_237661/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 = type { i32, ...
#include <stdio.h> int N; int deg[100001]; int par[100001]; int sib[100001]; int Depth(int); int Height(int); int main() { int j,i; scanf("%d", &N); for(i = 0; i < N; ++i) { par[i] = -1; sib[i] = -1; deg[i] = 0; } for(i = 0; i < N; i++) { int id, lef, rig; scanf("%d %d %d", &id, &lef, &rig...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_237704/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_237704/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 N 100000 typedef struct Ki{ int p; int r; int l; int h; }tree; int n; tree T[N]; void sibling(int i){ int j; for(j=0;j<n;j++){ if(T[i].p == -1){ printf("-1"); break; } else if(T[i].p==T[j].p&&i != j){ printf("%d",j); break; } if(j==...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_237748/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_237748/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.Ki = type { i32, i3...
#include<stdio.h> #define NIL -1 typedef struct{ int parent,sibling,leftgaki,rightgaki,degree; }Node; Node tree[100001]; int count=0,count3=0; //再帰関数、子供表示用 int count2[100001]; int n; int retdepth(int id){ //再帰で根っこまでの長さを計る if (tree[id].parent==NIL){ return count/2; } else { count++; return retdepth(t...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_237799/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_237799/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 = type { i32, ...
#include<stdio.h> #define MAX 100000 typedef struct{ int p,l,r; }Node; Node N [MAX]; int Depth(int i){//id の深さ 上中 int count=0; Node X=N[i]; for(;X.p!=-1;count++)X=N[X.p]; return count; } int Degree(int i){//子供の数 0-2 int count=0; if(N[i].r!=-1)count++; if(N[i].l!=-1)count++; return count; } int...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_237863/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_237863/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 = type { i32, ...
#include<stdio.h> #define MAX 25 typedef struct{ int parent; int left; int right; }Tree; int DEGREE( int ); int DEPTH( int ); int HEIGHT( int ); int get_sibling( int ); Tree T[MAX]; int main() { int i, n, id, left, right, degree, depth, height, sibling; scanf("%d", &n); for( i=0; i<n; i++ ) { ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_237906/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_237906/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.Tree = type { i32, ...
#include <stdio.h> #define NIL -1 typedef struct{ int left, right, par, dep, hei; }tree; tree t[100000]; void depth(int id, int d) { if (id == NIL) return; t[id].dep = d; depth(t[id].left,d+1); depth(t[id].right,d+1); } int height(int id) { int h1 = 0, h2 = 0; if (t[id].left != NIL) h1 = heig...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_237957/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_237957/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.tree = type { i32, ...
#include <stdio.h> #include <stdlib.h> int max(int a, int b) { if (a > b) return a; else return b; } int main(void) { int n, i, t, c, tmpt, tmpc = 0, maxc = 0; scanf("%d", &n); for (i = 0; i < n; i++) { scanf("%d%d", &t, &c); if (tmpc > 0) tmpc = max(0, tmpc - t + tmpt); tmpt = t; tmpc += c; ma...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_2380/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_2380/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...
// AOJ ALDS1_7_B Binary Trees // 2018.5.1 bal4u #include <stdio.h> #if 1 #define gc() getchar_unlocked() #else #define gc() getchar() #endif int in() { int n = 0, c = gc(); if (c == '-') { c = gc(); do n = 10*n + (c & 0xf), c = gc(); while (c >= '0'); return -n; } do n = 10*n + (c & 0xf), c = gc(); while (c >...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_238042/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_238042/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.TREE = type { i32, ...
#include <stdio.h> #define max(x,y) ((x>y)?x:y) typedef struct { int parent; int left; int right; } node_t; node_t node[100]; int n; void printTree(); int getSibling(int); int getDegree(int); int getDepth(int); int getHeight(int); int main() { int i; int ID, left, right; scanf("%d", &n); for (i = 0; i < n; i...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_238086/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_238086/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> #define NIL -1 struct Node_struct{int p, l, r, s, d;}; typedef struct Node_struct Node; Node T[25]; int D[25]; int H[25]; void print(int u){ int i, c; printf("node %d: parent = %d, sibling = %d, degree = %d, depth = %d, height = %d, ", u, T[u].p, T[u].s, T[u].d+1, D[u], H[u]); if(T[u].p == NIL) prin...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_238129/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_238129/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_struct = type ...
#include<stdio.h> #include<string.h> int main() { int i,t,a=0,b=0,c,d=0,s[10]={}; scanf("%d",&t); for(i=1;i<=t;i++){ scanf("%s %d %d",&s,&a,&b); if(a>=2400 && b>=2400 && b>a){ c=1; d=d+c; } else{ c=0; d=d+c; } } ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_23818/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_23818/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> #define max 10000 #define nil -1 #define min(x,y) (((x)>(y)) ?(x):(y)) struct node {int parent;int left;int right;}; struct node t[max]; int n,d[max],h[max]; void setdepth(int u,int a){ if(u==nil) return; d[u]=a; setdepth(t[u].left,a+1); setdepth(t[u].right,a+1); } int setheight(int u){ ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_238222/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_238222/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 = type { i32, ...
#include <stdio.h> #include <stdlib.h> #include <math.h> int main(void){ int n; scanf("%d", &n); int b[n+1]; for(int i = 1;i <= n;i++){ scanf("%d", &b[i]); } int j; int ans[n+1]; for(int i = n;i > 0;i--){ j = i; while(1){ if(b[j]==j){ ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_238273/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_238273/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 H, A, B; int h, n; scanf("%d%d%d", &H, &A, &B); n = 0; for (h = A; h <= B; h++){ if (H % h == 0){ n++; } } printf("%d\n", n); return (0); }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_238316/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_238316/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 i, x, j, n, temp1, temp2, neg; char buffer[65536]; x = fread(buffer, sizeof(char), sizeof(buffer), stdin); i=0; n=0; while(buffer[i]!='\n'){ n=n*10+(buffer[i]-'0'); i++; } i++; j=0; while(j<n && i<x){ while(buffer[i]!=' '){ i++;...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_23836/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_23836/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_unnam...
#include<stdio.h> int nei[200005], dist[200005], q[600005], qs, qe, n; int main(){ int i, j; scanf("%d", &n); for(i=0;i<n;i++){ scanf("%d", nei+i); nei[i]--; dist[i] = n+1; } qs = 0; qe = 1; q[0] = 0; dist[0] = 0; while(qe>qs){ i = q[qs++]; j = i-1; if(j>=0 && j<n && dist[i]+...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_23841/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_23841/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> // printf(), fgets() #include <stdlib.h> // qsort() #define N 5 int cmp_func(const void *l_, const void *r_) { const int* l = (const int*) l_; const int* r = (const int*) r_; if (*l > *r) return -1; if (*l < *r) return 1; return 0; } int main(int argc, char** argv) { ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_238460/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_238460/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 max(a,b) ((a)>(b)?(a):(b)) int arr[1010]; int main() { int m, n, i, j; scanf("%d", &n); for (i = 1; i <= n; i++) scanf("%d", &arr[i]); int maxn = 0; int cur = 0; arr[0] = 0, arr[n + 1] = 1001; n++; cur = 1; for (i = 1; i <= n; i++) { if (arr[i] == arr[i - 1] + 1) cur++; else { ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_23854/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_23854/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 in[5], i, j, swap; for (i = 0; i < 5; i++) { scanf("%d", &in[i]); } for (i = 0; i < 5; i++) { for (j = 0; j < 5; j++) { if (in[i] > in[j]) { swap = in[i]; in[i] = in[j]; in[j] = swap; } } } for (i = 0; i < 4; i++) { printf("%d ", in[i]); } printf("%...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_238626/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_238626/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 A[101]; int main(){ int t,n,i,j,a,k; scanf("%d",&n); for(a=0;a<n;a++) scanf("%d",&A[a]); int max=0; for(i=0;i<n;i++){ if(A[i]==1001-n+i){ max=n-1-i; break; } } for(j=n-1;j>=0;j--){ if(A[j]==j+1) { if(max<j) max=j; break; } } int count =0; for(k=1;k<=n;k++){ if(A...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_23867/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_23867/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 n[5]; int i,j,t; scanf("%d %d %d %d %d",&n[0],&n[1],&n[2],&n[3],&n[4]); for(i=0;i<5;i++){ for(j=1;j+i<5;j++){ if(n[j]>n[j-1]){ t=n[j]; n[j]=n[j-1]; n[j-1]=t; } } } printf("%d %d %d %d %d\n",n[0],n[1],n[2],n[3],n[4]); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_238712/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_238712/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.20180717 #include<stdio.h> #include<string.h> #include<stdlib.h> #include<stdbool.h> #include<time.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 min(int a,int b){i...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_238763/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_238763/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 prevsuuretu[12]; int suuretu[12]; int bunpu[12]; int suuzi[12]; int hyoulength; int length; int i; int kaisuu; int j; while(1) { scanf("%d",&length); if(length==0)break; for(i=0;i<length;i++) { scanf("%d",&suuretu[i]); prevsuuretu[i]=suuretu[i]; } kaisu...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_238806/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_238806/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> long ll[10000]={0},rr[10000]={0},hash[200000]={0}; int main() { long L,b,f,n,i,j,tot=0,st,flag,o,sum,w,op,ask; scanf("%ld %ld %ld\n",&L,&b,&f); scanf("%ld\n",&n); for(i=1;i<=n;i++) { scanf("%ld %ld\n",&ask,&op); if(ask==1) { st=1; flag=0; ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_23885/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_23885/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" @ll = dso_local local_unnamed...
#include <stdio.h> #include <stdlib.h> #include <math.h> int main(){ int x,y; scanf("%d %d", &x,&y); if(x % y == 0){ printf("-1"); return 0; } else{ int i; for(i=2;i<1000000000;i++){ if( (x*i) % y != 0){ printf("%d", x*i); retu...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_238893/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_238893/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 h1, h2, m1, m2, k; scanf("%d %d %d %d %d", &h1, &m1, &h2, &m2, &k); int ans = (m2-m1)+((h2-h1)*60)-k; printf("%d\n", ans); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_238943/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_238943/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 x , y, n,k, m,count=0,z; scanf("%d %d %d %d %d",&x,&y,&n,&m,&k); z=n-x; count=z*60; count+=m-y; count-=k; printf("%d",count); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_238994/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_238994/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 up_h, up_m, gt_h, gt_m, stu_m, all_m; scanf("%d %d %d %d %d", &up_h, &up_m, &gt_h, &gt_m, &stu_m); all_m = ((gt_h - up_h)*60)+(gt_m - up_m); printf("%d",all_m-stu_m); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_239043/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_239043/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 h1, m1, h2, m2, k; scanf("%d %d %d %d %d", &h1, &m1, &h2, &m2, &k); printf("%d\n", 60 * h2 + m2 - 60 * h1 - m1 - k); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_239087/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_239087/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> double x[20],y[20]; double d(int a,int b){ double ans; ans=sqrt((x[a]-x[b])*(x[a]-x[b])+(y[a]-y[b])*(y[a]-y[b])); return ans; } double tri(int f,int s,int t){ double sum,da=d(f,s),db=d(s,t),dc=d(t,f); double S; S=(da+db+dc)/2; sum=sqrt(S*(S-da)*(S-db)*(S...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_239144/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_239144/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" @x = dso_local global [20 x...
#include <stdio.h> #define N 20 int main(){ int i,n=0; double dx[N],dy[N]; double x,y,sum=0; while (scanf("%lf,%lf",&dx[n],&dy[n])!=EOF) n++; dx[n]=dx[0]; dy[n]=dy[0]; for (i=0;i<n;i++) sum+=(dx[i]-dx[i+1])*(dy[i]+dy[i+1]); printf("%f\n",sum/2); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_239201/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_239201/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 X; int price; scanf("%d\n", &N); X = N / 1.08; while (price < N) { price = X * 1.08; X++; } X--; if (price >= (N + 1)) printf(":(\n"); else printf("%d\n", X); return (0); }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_239245/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_239245/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 N,M,X; scanf("%lf", &N); X = ceil(N / 1.08); M = floor(1.08 * X); if(M == N){ printf("%.0lf", X); }else{ printf(":("); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_239302/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_239302/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> #define ll long long #define rep(i,l,r)for(ll i=(l);i<(r);i++) #define repp(i,l,r,k)for(ll i=(l);i<(r);i+=(k)) #define INF ((1LL<<62)-(1LL<<31)) #define max(p,q)((p)>(q)?(p):(q)) #define min(p,q)((p)<(q)?(p):(q)) #define bit(n,m)(((n)>>(m))&1)...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_239346/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_239346/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 <stdlib.h> int i,j,k,n,m,l,x,y,route[2][21][21]; int main(){ scanf("%d",&n); for(i=0;i<n;i++){ for(j=0;j<n;j++){ if(i!=j)route[0][i][j]=999999999; } } scanf("%d",&m); for(i=0;i<m;i++){ scanf("%d,%d,%d,%d",&j,&k,&x,&y); route[0][j-1][k-1]=x; route[0][k-...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_239397/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_239397/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,d; scanf("%d",&a); b=a/3600; c=a%3600/60; d=a%3600%60; printf("%d:%d:%d\n",b,c,d); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_239447/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_239447/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 S,h,m,s; scanf("%d",&S); h=S/3600; m=S%3600/60; s=S%3600%60; printf("%d:%d:%d\n",h,m,s); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_239490/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_239490/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 S,h,m,s; scanf("%d",&S); h=S/3600; m=S%3600/60; s=S%3600%60; printf("%d:%d:%d\n",h,m,s); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_239540/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_239540/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 t, sec, min, hour; scanf("%d", &t); sec = t % 60; t = (t - sec) / 60; min = t % 60; hour = (t - min) / 60; printf("%d:%d:%d\n", hour, min, sec); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_239584/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_239584/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 h,m,s; scanf("%d",&s); h=s/3600; s=s%3600; m=s/60; s=s%60; printf("%d:%d:%d\n",h,m,s); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_239627/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_239627/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 S; scanf("%d",&S); printf("%d:%d:%d\n",S/3600,(S/60)%60,S%60); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_239670/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_239670/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 S, h, m, s; scanf("%d",&S); h = S/3600; m = (S - h*3600)/60; s = S - h*3600 -m* 60; printf("%d:%d:%d\n",h,m,s); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_239713/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_239713/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 S,a,b,c,d; scanf("%d",&S); a=S/3600; b=S%3600; c=b/60; d=b%60; printf("%d:%d:%d\n",a,c,d); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_239757/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_239757/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 <stdbool.h> #define MAX 4010 #define MOD 1000000007 #define clr(ar) memset(ar, 0, sizeof(ar)) #define read() freopen("lol.txt", "r", stdin) int S[4010][4010]; void Generate(){ int i, j; S[0][0] = 1; for (i = 1; i < MAX; i++){ S[i][0] = 0; f...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_23980/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_23980/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" @S = dso_local local_unnamed_...
#include <stdio.h> int main(void) { int S,mm,ss; scanf("%d",&S); if(S>=0 && S<86400) { ss= S % 60; S /=60; mm = S % 60; S /=60; printf("%d:%d:%d\n",S,mm,ss); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_239843/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_239843/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 S, h, m, s; scanf("%d", &S); h = S/3600; m = (S-3600*h)/60; s = S-3600*h-60*m; printf("%d:%d:%d\n",h,m,s); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_239887/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_239887/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() { long long int t; scanf("%lld",&t); while(t--){ long long int n; scanf("%lld",&n); long long int arr[n+1],pro[n+1],max=0; for(int i=0;i<n;i++){ scanf("%lld",&arr[i]); if(i > 0){ pro[i] = arr[i]*arr[i-1]; if(pro[i...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_23993/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_23993/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 s,h,m,i; int S; scanf("%d",&S); i=S%3600; s=i%60; m=(i-s)/60; h=(S-m*60-s)/3600; printf("%d:%d:%d\n",h,m,s); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_239973/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_239973/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 str[10]; int second; fgets(str, sizeof(str), stdin); sscanf(str, "%d", &second); printf("%d:", second / 3600 ); printf("%d:", second % 3600 / 60 ); printf("%d", second % 60); printf("\n"); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_240014/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_240014/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 time; scanf("%d",&time); int h = time/3600; int ha = time%3600; int m = ha/60; int s= ha%60; printf("%d:%d:%d\n",h,m,s); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_240058/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_240058/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 s,m,h,x; scanf("%d",&x); h=x/3600; m=(x-(h*3600))/60; s=(x-(h*3600+m*60)); printf("%d:%d:%d\n",h,m,s); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_240100/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_240100/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 time, hour, minute, second; scanf("%d", &time); hour = time / (60 * 60); minute = (time % 3600) / 60; second = time % 60; printf("%d:%d:%d\n", hour, minute, second); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_240144/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_240144/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=0,b=0,c,i; scanf("%d",&c); for(i=0;i<24;i++){ if(c>=3600){ c-=3600; a+=1; } } for(i=0;i<60;i++){ if(c>=60){ c-=60; b+=1; } } printf("%d:%d:%d\n",a,b,c); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_240188/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_240188/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 x; scanf("%ld", &x); printf("%d:%d:%d\n", x/3600, (x/60)%60, x%60); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_240238/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_240238/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 s; scanf("%d", &s); printf("%d:%d:%d\n", s/3600, s/60%60, s%60); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_240281/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_240281/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 S; int h,m,s; int s1; scanf("%d", &S); while(1){ if(0<=S && 86400>S){ h=S/3600; s1=S-h*3600; m=s1/60; s=s1-m*60; break; }else{ scanf("%d", &S); continue; } } printf("%d:%d:%d\n", h , m , s); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_240331/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_240331/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 S,h,m,s; scanf("%d",&S); h=S/3600; m=(S/60)-(h*60); s=S%60; printf("%d:%d:%d\n",h,m,s); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_240375/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_240375/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 S,h,m,s; scanf("%d",&S); h=S/3600; m=S%3600/60; s=S%3600%60; printf("%d:%d:%d\n",h,m,s); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_240418/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_240418/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 hours, minites, seconds; int time; scanf("%d", &time); for (hours = 0; time >= 60*60; hours++) { time -= 60*60; } for (minites = 0; time >= 60; minites++) { time -= 60; } seconds = time; printf("%d:%d:%d\n", hours, minites, sec...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_240461/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_240461/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; scanf("%d",&a); printf("%d:%d:%d\n",a/3600,(a-(a/3600)*3600)/60,a-(((a/3600)*3600)+((a-(a/3600)*3600)/60)*60)); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_240511/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_240511/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 S, h, m, s; scanf("%d", &S); h = S/3600; m = (S-h*3600)/60; s = S-h*3600-m*60; printf("%d:%d:%d\n", h, m, s); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_240555/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_240555/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 data; int h, m, s; scanf("%d", &data); h = data / 3600; data = data % 3600; m = data / 60; s = data % 60; printf("%d:%d:%d\n", h, m, s); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_240599/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_240599/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 s; scanf ("%d", &s); int m; int h; h = s/60/60; m = (s-h*60*60)/60; s = s-h*60*60-m*60; printf ("%d:%d:%d\n",h,m,s); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_240641/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_240641/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; scanf("%d",&a); printf("%d:%d:%d\n",a/3600,a%3600/60,a%3600%60); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_240685/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_240685/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 S; int h, m, s; scanf("%d", &S); h = S / 3600; m = (S % 3600) / 60; s = (S % 3600) % 60; printf("%d:%d:%d\n", h, m, s); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_240728/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_240728/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 S, h, m, s; scanf("%d", &S); h = S / 3600; S = S % 3600; m = S / 60; S = S % 60; s = S; printf("%d:%d:%d\n", h, m, s); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_240779/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_240779/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 s,h,m,sec; scanf("%d",&s); h = s/3600; m = (s%3600)/60; sec = (s%3600)%60; printf("%d:%d:%d\n",h,m,sec); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_240829/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_240829/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 $S$,$h$,$m$,$s$; scanf("%d",&$S$); $h$ = $S$ / 3600; $m$ = ($S$ - ($h$ * 3600))/60; $s$ = ($S$ - ($h$ * 3600 + $m$ * 60)); printf("%d:%d:%d\n",$h$,$m$,$s$); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_240872/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_240872/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 sec; int h; int m; int s; scanf("%d", &sec); h = sec / 3600; m = (sec - h * 3600) / 60; s = sec - h * 3600 - m * 60; printf("%d:%d:%d\n", h, m, s); return (0); }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_240922/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_240922/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 S,h,m,s; scanf("%d",&S); if("0<=S<86400"){ s=S%60; m=(S-s)%3600/60; h=(S-s-60*m)/3600; printf("%d:%d:%d\n",h,m,s); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_240966/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_240966/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 S,h,m,s; int minute; scanf("%d",&S); if(0>S||86400<=S) printf("Too Large\n"); minute = S/60; h = minute / 60; m = minute % 60; s = S % 60; printf("%d:%d:%d\n",h,m,s); }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_241015/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_241015/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, h, m, s; scanf("%d\n", &a); s = a % 60; a = (a - s) / 60; m = a % 60; a = (a - m) / 60; h = a; printf("%d:%d:%d\n", h, m, s); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_241066/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_241066/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 s, m, h; scanf("%d", &s); h = s / 3600; s = s % 3600; m = s / 60; s = s % 60; printf("%d:%d:%d\n", h, m, s); }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_241109/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_241109/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 v,h,t,s; scanf("%d",&v); h = v / 3600; v = v % 3600; t = v / 60; v = v % 60; s = v ; printf("%d:%d:%d\n", h, t, s); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_241152/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_241152/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...