Source_Code
stringlengths
69
484k
IR_Original
stringlengths
2.05k
17.9M
#include <stdio.h> #include <stdlib.h> int cmp(const void *a, const void *b) { return (int)*(char*)a - *(char*)b; } int main() { int tc; char s[100001]; scanf("%d", &tc); while(tc--) { int n, k, l = 0, p = 0, i; char r[100001] = {0}; scanf("%d %d %s", &n, &k, s); qsort(s, n, sizeof(char), cmp); if(s...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_2102/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_2102/source.c" target datalayout = "e-m:e-p270: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> #include <stdlib.h> #include <unistd.h> #include <string.h> #include <stdio.h> int main(int argc, char const *argv[]) { int n,k; scanf("%d %d\n", &n ,&k); char s[50]; scanf("%s",s); char c = *(s+k-1); *(s+k-1) = c - ('A'-'a'); printf("%s", s); }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_210242/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_210242/source.c" target datalayout = "e-m:e-p270: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,i; char S[50]; scanf("%d %d",&N,&K); for(i=0;i<N;i++){ scanf("%s",&S[i]); if(i==K-1) S[i]=S[i]+32; } for(i=0;i<N;i++) printf("%c",S[i]); return(0); }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_210293/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_210293/source.c" target datalayout = "e-m:e-p270: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; char s[51]; scanf("%d %d", &n, &k); scanf("%s", s); s[k-1] += ('a' - 'A'); printf("%s", s); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_210336/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_210336/source.c" target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-pc-linux-gnu" @.str = private unnamed_add...
#include <stdio.h> int main(void) { // your code goes here int n; scanf("%d",&n); int a[n+1],i,c=0,s,k=0; a[0]=0; for(i=1;i<=n;i++){ scanf("%d",&a[i]); s = a[i]-a[i-1]; // printf("%d\n",s); if(s>k){ c+=s-k; k=0; }else{ s =...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_21038/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_21038/source.c" target datalayout = "e-m:e-p270: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, K; scanf("%d %d", &N, &K); char S[128]; scanf("%s", S); S[K-1] += ('a' - 'A'); printf("%s\n", S); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_210422/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_210422/source.c" target datalayout = "e-m:e-p270: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> const int STD = 1000000007; int main(void) { int s; int i, j; int df[2001] = {0}; scanf("%d", &s); df[0] = 0; df[1] = 0; df[2] = 0; df[3] = 1; df[4] = 1; df[5] = 1; for (i = 6; i <= s; i...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_210466/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_210466/source.c" target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-pc-linux-gnu" @STD = dso_local local_unna...
#include <stdio.h> #define REP(i,a,b) for (i=(a); i<(b); ++i) #define rep(i,n) REP(i,0,n) #define MAX(a, b) ((a) > (b) ? (a) : (b)) #define EPS 1e-12 double a[101][101]; double memo[101][101][101]; int b[101]; double solve(int n, int m, int k, int p) { double res; int i, j; if (m == 1) return 1; if (me...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_210509/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_210509/source.c" target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-pc-linux-gnu" @memo = dso_local local_unn...
#include<stdio.h> #include<string.h> #include<math.h> #include<time.h> #define ll long long #define lli long long int #define pf printf #define sf scanf #define nl printf("\n") #define pfx printf("x") int main() { lli n,i,a[100100],b[100100]; scanf("%I64d",&n); for(i=1;i<=n;i++) { sf("%I64d",&a[...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_21056/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_21056/source.c" target datalayout = "e-m:e-p270: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,s; scanf("%d %d", &n, &s); s*=100; int i, money; int x,y, sweets, ans=-1; for (i=0; i<n; i++) { money =s; scanf("%d %d",&x, &y); x = (x*100)+y; if (money>=x) { money-=x; sweets = money%100; if (sweets>ans) ans = sweets; } } // if (ans==0) printf("-1\n")...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_21061/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_21061/source.c" target datalayout = "e-m:e-p270: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 ...
/* ex5_4 kt125*/ #include<stdio.h> #include<string.h> int main(void){ int count = 0, ans=0; char str[11], *ptr; scanf("%s", &str[0]); //'A','G','C','T'の全てを'X'に置き換える。 for(int i= 0; i< strlen(str);i++){ if(str[i] == 'A' || str[i] == 'C' || str[i] == 'G' || str[i] == 'T'){ ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_210653/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_210653/source.c" target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-pc-linux-gnu" @.str = private unnamed_add...
#include <stdio.h> #include <string.h> int main(){ char s[11];int i,a=0,l=0; scanf("%s",s); for(i=0;i<strlen(s);i++){ if(s[i]=='A'||s[i]=='T'||s[i]=='G'||s[i]=='C'){l++;a=(a<l?l:a);} else l=0; } printf("%d",a); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_210697/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_210697/source.c" target datalayout = "e-m:e-p270: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,s; scanf("%d", &n); scanf("%d", &s); int d,c,max=-1; int flag=0; for(i=0;i<n;i++) { scanf("%d",&d); scanf("%d",&c); if(c==0 && d<=s) { if(max<0) max=0; flag=1; } else if(d+1<=s) { if(max<100-c) max=100-c; flag=1; } } if(flag==0) p...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_21074/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_21074/source.c" target datalayout = "e-m:e-p270: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 length(const char s[]) { int i,j=0,len=0,count=0,max=0; while(s[len]) len++; for(i=0;i<len;i++){ if(s[i]=='A'||s[i]=='C'||s[i]=='G'||s[i]=='T'){ count++; j=count; }else{ if(max<j){ j=count; max=j; } count=0; } } if(max<j) ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_210783/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_210783/source.c" target datalayout = "e-m:e-p270: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...
#if 0 cat <<EOF >mistaken-paste #endif // thx Ebi-chan! #pragma GCC diagnostic ignored "-Wincompatible-pointer-types" #define _USE_MATH_DEFINES #include <stdio.h> #include <stdint.h> #include <stdlib.h> #include <string.h> #include <stdbool.h> #include <math.h> #include <time.h> #define BIG 2000000007 #define VERYBI...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_210826/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_210826/source.c" target datalayout = "e-m:e-p270: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.hwll = type { i64, ...
#include<stdio.h> int main() { long int n,dollar,energy,i; scanf("%ld",&n); long int a[n+1]; a[0]=0; for(i=1;i<=n;i++) scanf("%ld",&a[i]); energy=0; dollar=a[1]-0; //printf("%ld %ld\n",dollar,energy); for(i=1;i<n;i++) { if(a[i+1]>a[i]) { if(ene...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_21087/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_21087/source.c" target datalayout = "e-m:e-p270: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) { char S[11]; int i, count = 0, ans = 0; scanf("%s", &S); for (i = 0; i < 11; ++i) { switch (S[i]) { case'A': case'G': case'C': case'T': ++count; break; default: if (count > ans) { ans = count; count = 0; } else { ans = ans; count = 0; ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_210912/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_210912/source.c" target datalayout = "e-m:e-p270: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) { char b[11]; int i = 0,max = 0,coun = 0; scanf("%s",&b); for(i = 0;i < strlen(b) + 1;i++) { if(b[i] == 'A'|| b[i] == 'C'|| b[i] == 'G'|| b[i] == 'T') coun++; else{ if(coun >= max){ max = coun; coun = 0; } } } p...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_210956/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_210956/source.c" target datalayout = "e-m:e-p270: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 i,flag1=0,flag2=0; char s[12]; scanf("%s",s); for(i=0;i<strlen(s);i++) { if(s[i]=='A'||s[i]=='T'||s[i]=='C'||s[i]=='G') { flag1++; if(flag1>flag2) flag2=flag1; } else ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_211012/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_211012/source.c" target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-pc-linux-gnu" @.str = private unnamed_add...
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <math.h> #include <limits.h> #define REP(i,n) for(i=0;i<n;i++) int iin() { int i; scanf("%d", &i); return i; } long long llin() { long long i; scanf("%lld", &i); return i; } double din() { double i; scanf("%lf", &i)...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_211056/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_211056/source.c" target datalayout = "e-m:e-p270: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...
/* Coached by rainboy */ #include <stdio.h> #include <string.h> #define N 100000 #define V 100000 int max(int a, int b) { return a > b ? a : b; } int main() { static int vv[N], kk[V + 1], mm1[2], mm2[2]; int n, i, max1, max2, v_, v, r; scanf("%d", &n); for (i = 0; i < n; i++) scanf("%d", &vv[i]); for (r = 0...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_211106/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_211106/source.c" target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-pc-linux-gnu" @main.vv = internal global ...
#include <stdio.h> #include <string.h> #include <stdlib.h> #include <math.h> int main(){ int i,j; int l; int n; int p[100000]; int max1=0; int max2=0; int max11,max22=0; int maxnum1; int maxnum2; int maxnum11; int maxnum22; int a,b=0; for(i=0; i<100000; i++){ p[i]=0; } scanf("%d",&n...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_211157/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_211157/source.c" target datalayout = "e-m:e-p270: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,s; scanf("%d %d",&n,&s); int x[n],y[n],i,j,temp,f=0; for(i=0;i<n;i++) scanf("%d%d",&x[i],&y[i]); for(i=0;i<n;i++) for(j=0;j<n-1;j++) { if(y[j]>y[j+1]) { temp=y[j]; y[j]=y[j+1]; y[j+1]=temp; ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_21120/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_21120/source.c" target datalayout = "e-m:e-p270: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,k; scanf("%d%d",&n,&k); if((n + 1) / 2 >= k) { puts("YES"); } else { puts("NO"); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_211243/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_211243/source.c" target datalayout = "e-m:e-p270: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 here! int N,K,num=0; scanf("%d %d",&N,&K); if(N%2==0){ if(N/2>=K){ printf("YES\n"); }else{ printf("NO\n"); } }else{ if((N+1)/2>=K){ printf("YES\n"); }else{ ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_211287/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_211287/source.c" target datalayout = "e-m:e-p270: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> long long int gcd(long long int a,long long int b) { if (b == 0) return a; return gcd(b, a % b); } int main() { long long int t; scanf("%lld",&t); while(t--) { long long int n,ans; scanf("%lld",&n); ans=gcd(n,100); ans=(10...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_21133/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_21133/source.c" target datalayout = "e-m:e-p270: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 points[101]; int main(){ int n, i, j; scanf("%d", &n); for(i = 0;i < n * (n - 1) / 2;i++){ int ai, bi, ci, di; scanf("%d%d%d%d", &ai, &bi, &ci, &di); if(ci == di){ points[ai]++; points[bi]++; } else if(ci > di){ points[ai] += 3; } else{ p...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_211388/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_211388/source.c" target datalayout = "e-m:e-p270: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 a, b, c, k; scanf("%lld %lld %lld %lld", &a, &b, &c, &k); long long int ans; if(k%2) ans = b - a; else ans = a - b; printf("%lld\n", ans); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_211438/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_211438/source.c" target datalayout = "e-m:e-p270: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; long long tak,nak,hik,K,Un=10000000000000000000; scanf("%lld %lld %lld %lld",&tak,&nak,&hik,&K); if(tak-nak>=Un&&Un-(tak-nak)<=0){ if(K%2==0){ printf("%lld\n",tak-nak); }else if(K%2==1){ printf("%lld\n",nak-tak); } }else{ printf("Unfair\n"); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_211496/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_211496/source.c" target datalayout = "e-m:e-p270: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 compareInt(const void* a, const void* b) { int aNum = *(int*)a; int bNum = *(int*)b; return aNum - bNum; } int main(void){ int n, x; int a[105]; scanf("%d %d", &n,&x); //int sum = 0; for(int i=0;i<n;i++){ scanf("%d", &a[i]); //sum+=a[i]; } ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_211582/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_211582/source.c" target datalayout = "e-m:e-p270: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> #include <string.h> #define ll long long #define rep(i,n) for(ll i=0;i<(n);i++) #define max(p,q) ((p)>(q)?(p):(q)) #define min(p,q) ((p)<(q)?(p):(q)) #define chmax(a,b) ((a)=(a)>(b)?(a):(b)) #define chmin(a,b) ((a)=(a)<(b)?(a):(b)) #define abs(p) ((p)>=(0)?(p):(-...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_211625/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_211625/source.c" target datalayout = "e-m:e-p270: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, x; scanf("%d %d", &n, &x); int i; int a[102]; for (i = 0; i < n; i++) scanf("%d", &a[i]); int p; for (i = 0; i < n - 1; i++) if (a[i] > a[i + 1]) { p = a[i]; a[i] = a[i + 1]; a[i + 1] = p; ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_211683/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_211683/source.c" target datalayout = "e-m:e-p270: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...
//Binary Search Tree 1 #include <stdio.h> #include <stdlib.h> struct node{ int key; struct node *left,*right,*parent; }; typedef struct node Node; Node *rootnode; Node *NIL; void Insert(int ); void Preorder(Node *); void Inorder(Node *); int main(void){ int n,i,key; char command[6]; scanf("%d",&n); for(i...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_211733/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_211733/source.c" target datalayout = "e-m:e-p270: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> #define N_MAX 500001 struct node{ int key; struct node *right; struct node *left; struct node *parent; }; typedef struct node *Node; Node root = NULL; void insert(int k){ Node y = NULL; Node x = root; Node z; z = malloc(sizeof(struct node))...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_211777/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_211777/source.c" target datalayout = "e-m:e-p270: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() { int t,i; scanf("%d",&t); for(i=0;i<t;i++){ int n,j,k=0; scanf("%d",&n); int a[n]; for(j=0;j<n;j++){ scanf("%d",&a[j]); } for(j=0;j<n;j++){ if(j+1==a[j]){ k++; } } ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_21182/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_21182/source.c" target datalayout = "e-m:e-p270: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> #define NIL NULL typedef struct node *Node; struct node{ int key; Node Right; Node Left; Node Parent; }; Node root; void insert(int k) { Node y = NIL; Node x = root; Node z; z = malloc(sizeof(struct node)); z->key = k; z->Left = NIL; z->Right = NIL; while(x !...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_211863/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_211863/source.c" target datalayout = "e-m:e-p270: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> struct node{ struct node *right; struct node *left; struct node *parent; int key; }; typedef struct node * Node; #define NIL NULL Node root; Node treeMinimum(Node x){ } Node treeMaximum(Node x){ } Node treeSearch(Node u, int k){ } Node treeSuccessor(Node x){ } void tr...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_211920/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_211920/source.c" target datalayout = "e-m:e-p270: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 { ptr, ...
#include<stdio.h> #include<stdlib.h> #define NIL NULL typedef struct node{ int key; struct node *l; struct node *r; struct node *p; } Node; typedef struct node* NodePointer; NodePointer root; void insert(int key){ NodePointer x, y, z; y = NIL; x = root; z = malloc(sizeof(struct node)); z->key...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_211964/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_211964/source.c" target datalayout = "e-m:e-p270: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> #define NIL NULL struct node{ struct node *right; struct node *left; struct node *parent; int key; }; typedef struct node * Node; Node root; Node treeMinimum(Node x){ } Node treeMaximum(Node x){ } Node treeSearch(Node u, int k){ } Node treeSuccessor(Node x){ } void ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_212028/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_212028/source.c" target datalayout = "e-m:e-p270: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 { ptr, ...
#include <stdio.h> #include <stdlib.h> struct node{ struct node *right; struct node *left; struct node *parent; int key; }; typedef struct node * Node; #define NIL NULL void insert(int); void inorder(Node); void preorder(Node); Node root; int main(){ int n, i, x; char com[20]; scanf("%d", &n); ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_212071/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_212071/source.c" target datalayout = "e-m:e-p270: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 { ptr, ...
#include<stdio.h> #include<string.h> #include <stdlib.h> struct Node{ int key; struct Node *p,*l,*r; }; struct Node *root,*NIL; void insert(int); void inorder(struct Node*); void preorder(struct Node*); int main(){ int m,x; int i; char k[10]; scanf("%d",&m); for(i=0; i < m; i++){ scanf("%s",k); ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_212114/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_212114/source.c" target datalayout = "e-m:e-p270: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 <string.h> #include <stdlib.h> struct Node{ int key; struct Node *right,*left,*parent; }; //typedef struct Node; struct Node *root,*NIL; void insert(int k){ struct Node *y=NIL; struct Node *x=root; struct Node *z; z=(struct Node *)malloc(sizeof(struct Node)); z->key=k; z->l...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_212165/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_212165/source.c" target datalayout = "e-m:e-p270: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> struct node{ struct node *right; struct node *left; struct node *parent; int key; }; typedef struct node * Node; #define NIL NULL Node root; void insert(int k){ Node y = NIL; Node x = root; Node z; z = malloc(sizeof(struct node)); z->key = k; z->left = NIL; ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_212208/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_212208/source.c" target datalayout = "e-m:e-p270: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 { ptr, ...
#include<stdio.h> #include<stdlib.h> struct node{ struct node *Left; struct node *Right; struct node *Parent; int ndkey; }; typedef struct node * NodePointer; NodePointer root = NULL; NodePointer NIL = NULL; NodePointer makeNode(){ NodePointer node = malloc(sizeof(struct node)); node->Left =...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_212259/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_212259/source.c" target datalayout = "e-m:e-p270: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 { ptr, ...
#include<stdio.h> #include<stdlib.h> #define NIL NULL typedef struct Node{ int key; struct Node *right,*left,*parent; }Node; Node *root; void insert(int k){ Node *y=NIL; Node *x=root; Node *z; z=malloc(sizeof(Node)); z->key=k; z->left=NIL; z->right=NIL; while(x!=NIL){ y=x; if(z->key < x-...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_212301/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_212301/source.c" target datalayout = "e-m:e-p270: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> int get_int() { int n = 0; int c = getchar_unlocked(); if(c == 45) { c = getchar_unlocked(); while(47 < c && c < 58) n = 10 * n + (c & 0xf), c = getchar_unlocked(); return -n; } else if(c < 48 || 57 < c) return c; while(47 < c && c < 58...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_212345/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_212345/source.c" target datalayout = "e-m:e-p270: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._IO_FILE = type { i...
#include<stdio.h> #include<stdlib.h> struct node{ struct node *right; struct node *left; struct node *parent; int key; }; typedef struct node * Node; #define NIL NULL Node root; Node treeMinimum(Node x){ } Node treeSearch(Node u, int k){ } Node treeSuccessor(Node x){ } void treeDelete(Node z){ Nod...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_212396/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_212396/source.c" target datalayout = "e-m:e-p270: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 { ptr, ...
#include<stdio.h> #include<stdlib.h> #define NIL NULL struct node { struct node *right; struct node *left; struct node *parent; int key; }; typedef struct node * Node; Node root; Node treeMinimum(Node x) { } Node treeSearch(Node u, int k) { } Node treeSuccessor(Node x) { } void treeDelete(Node z) { ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_212446/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_212446/source.c" target datalayout = "e-m:e-p270: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 { ptr, ...
#include <stdio.h> int gcd(int a,int b){ if(a<b){int swap=a;a=b;b=swap;} if(a%b==0) return b; else return gcd(b,a%b); } int main(){ int t; scanf("%d",&t); while(t--){ int k; scanf("%d",&k); if(k==0 || k==100) printf("1\n"); else{ int div=gcd(k,100-k);...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_21249/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_21249/source.c" target datalayout = "e-m:e-p270: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 t,a,b,i,c,max,min,m,n,r; scanf("%d",&t); for(i=0;i<t;i++) { scanf("%d",&a); b=100; max=a>b?a:b; min=a<b?a:b; m=max; n=min; do{ r=max%min; max=min; min=r; }while(r!=0); printf("%d\n",b/max); } }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_21254/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_21254/source.c" target datalayout = "e-m:e-p270: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> struct node{ struct node *right; struct node *left; struct node *parent; int key; }; typedef struct node * Node; #define NIL NULL Node root; void inorder(Node x){ if(x==NIL) return; inorder(x->left); printf(" %d",x->key); inorder(x->right); } void preorder(No...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_212590/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_212590/source.c" target datalayout = "e-m:e-p270: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 { ptr, ...
#include <stdio.h> #include <stdlib.h> #include <string.h> struct node{ struct node *right; struct node *left; struct node *parent; int key; }; typedef struct node * Node; #define NIL NULL Node root; void insert(int k){ Node y = NIL; Node x = root; Node z; z = malloc(sizeof(struct node)); z->key = ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_212640/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_212640/source.c" target datalayout = "e-m:e-p270: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 { ptr, ...
#include <stdio.h> #include <stdlib.h> typedef struct{ int key; int left; int right; } Node; void insert(Node*, int, int); void print1(Node*, int); void print2(Node*, int); int main() { char s[10]; Node *t; int m; int a; int i; int cnt=0; scanf("%d", &m); t=(...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_212691/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_212691/source.c" target datalayout = "e-m:e-p270: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> struct Node{ int key; struct Node *right,*left,*parent; }; struct Node *root,*NIL; struct Node * find(struct Node *u,int k){ while(u!=NIL&&k!=u->key){ if(k < u->key) u=u->left; else u = u->right; } return u; } void i...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_212734/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_212734/source.c" target datalayout = "e-m:e-p270: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> struct Node{ int key; struct Node *right, *left, *parent; }; struct Node *root , *NIL; void insert(int); void inorder(struct Node*); void preorder(struct Node*); int main(){ int n,i,x; char c[10]; scanf("%d",&n); for(i=0;i<n;i++){ scanf("%s",c); if(c[0]=='i'){ ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_212778/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_212778/source.c" target datalayout = "e-m:e-p270: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> struct node{ struct node *right; struct node *left; struct node *parent; int key; }; typedef struct node * Node; #define NIL NULL Node root; Node treeMinimum(Node x){ while( x->left != NIL){ x = x->left; } return x; } Node treeMaximum(Node x){ } Node tree...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_212828/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_212828/source.c" target datalayout = "e-m:e-p270: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 { ptr, ...
#include<stdio.h> #include<stdlib.h> #include<string.h> #define N 500000 #define DUMMY 2000000001 struct Node{ int key; struct Node *left,*right; }; struct Node *make_node(int x){ struct Node *node = malloc(sizeof(struct Node)); if(node != NULL){ node->key = x; node->left = NULL; node->right = NUL...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_212871/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_212871/source.c" target datalayout = "e-m:e-p270: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 <math.h> int main(void) { while(1){ long long int n; scanf("%lld",&n); if(n==0) break; long long int y; scanf("%lld",&y); long long int i,b[n],r[n],t[n]; for(i=0;i<n;i++){ scanf("%lld %lld %lld",&b[i],&r[i],&t[i]); } double a[n]; for(i=0;i<n;i++){ if(t[i]==1){ ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_212929/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_212929/source.c" target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-pc-linux-gnu" @.str = private unnamed_add...
#include<stdio.h> int main(void) { int n,i; int a[100001]; int b[100000]; long int sum=0; scanf("%d",&n); for(i=0;i<n+1;i++) scanf("%d",&a[i]); for(i=0;i<n;i++) scanf("%d",&b[i]); for(i=0;i<n;i++){ if(a[n-i]>=b[n-1-i]) sum+=b[n-1-i]; else{ sum+=a[n-i]; b[n-1-i]-=a[n-i]; if(a[n-1-i]>=b[n...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_212972/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_212972/source.c" target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-pc-linux-gnu" @.str = private unnamed_add...
#include<stdio.h> int main(void) { int n; scanf("%d", &n); long long int a[100005]={0}, b[100005]={0}; int i; for (i=0;i<=n;i++){ scanf("%lld", &a[i]); } for (i=0;i<n;i++){ scanf("%lld", &b[i]); } long long int ans = 0; for (i=0;i<n;i++) { if (a[i]<=b[i]) { ans += a[i]; b[i] -= a[i]; ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_213014/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_213014/source.c" target datalayout = "e-m:e-p270: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 n, i; scanf("%ld", &n); long a[n + 1], b[n]; for ( i = 0; i <= n; i++ ) { scanf("%ld", &a[i]); } for ( i = 0; i < n; i++ ) { scanf("%ld", &b[i]); } long ans = 0, remain_a = 0, remain_b = 0; /* 1 番目の街から n 番目の街までを考える */ for...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_213058/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_213058/source.c" target datalayout = "e-m:e-p270: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 n,a[100010],b[100010],ans=0; scanf("%lld",&n); int i,j,tmp=0; for(i=0;i<n+1;i++){ scanf("%lld",&a[i]); } for(i=0;i<n;i++){ scanf("%lld",&b[i]); } for(i=0;i<n;i++){ if(a[i]>=b[i]) ans+=b[i]; else{ if(a[i]+a[i+1]<=b[i]){ ans +=a[i]+a[i+1]; a[i+1]=...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_213100/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_213100/source.c" target datalayout = "e-m:e-p270: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 HEIGHT 12 #define WIDTH 6 int calcChain( void ); int deleteBlock( void ); int findGroup( int, int ); int findGroup_body( int, int, char, int, int ); void deleteGroup( int, int ); void deleteGroup_body( int, int, int, int ); void fallBlock( void ); typedef struct { char color; int state; ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_213151/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_213151/source.c" target datalayout = "e-m:e-p270: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.FIELD = type { i8, ...
#include <stdio.h> #include <stdlib.h> void solver(int m1, int m2) { if (m1==m2) { printf("0\n"); return; } printf("1\n"); } int main(int argc, char *argv[]) { int m1, m2, d1, d2; scanf("%d%d", &m1, &d1); scanf("%d%d", &m2, &d2); solver(m1, m2); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_213201/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_213201/source.c" target datalayout = "e-m:e-p270: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.2 = private unnamed_a...
#include <stdio.h> #include <string.h> int main(void){ int M1, D1, M2, D2; scanf("%d %d", &M1, &D1); scanf("%d %d", &M2, &D2); if(D2==1){ printf("1"); }else{ printf("0"); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_213252/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_213252/source.c" target datalayout = "e-m:e-p270: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 m1,m2,d1,d2; scanf("%d%d%d%d",&m1,&d1,&m2,&d2); if(m2-m1 == 1)printf("1\n"); else printf("0\n"); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_213302/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_213302/source.c" target datalayout = "e-m:e-p270: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 abs(a) ((a)>(0)?(a):-(a)) int n,A,B,C; int min(int a,int b,int c,int d){ int min=a; if(b<min)min=b; if(c<min)min=c; if(d<min)min=d; return min; } int dfs(int a,int b,int c,int d,int *l){ if(d==n&&(a*b*c>0)) return abs(a-A)+abs(b-B)+abs(c-C)-30; else if(d==n)return 1e9; else{ ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_213353/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_213353/source.c" target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-pc-linux-gnu" @n = dso_local global i32 0...
#include <stdio.h> int main(void) { int X,Y; scanf("%d %d",&X,&Y); if(Y%4 == 0 && Y/4 <= X && X <= Y/2){ printf("Yes"); }else if(Y%2 == 0 && Y%4 != 0 && Y/4+1 <= X && X <= Y/2){ printf("Yes"); }else{ printf("No"); } }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_213397/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_213397/source.c" target datalayout = "e-m:e-p270: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 t; scanf("%d",&t); while(t--) { long long int x,n; scanf("%lld %lld",&x,&n); if(x%2 == 0) { if(n%4 == 1) { x = x-n; } if(n%4 == 2) { x++; } if(n%4 == 3) { x = x + n + 1; } } else { if(n%4 == 1) { x = x + n; } if...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_21344/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_21344/source.c" target datalayout = "e-m:e-p270: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 <stdbool.h> int main() { int x, y; scanf("%d %d", &x, &y); bool ok = 0; for (int i = 0; i <= x; i++) { if (i * 2 + (x - i) * 4 == y) ok = 1; } if (ok) printf("Yes\n"); else printf("No\n"); }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_213483/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_213483/source.c" target datalayout = "e-m:e-p270: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 x, y; scanf("%d %d", &x, &y); if (2*x <= y && y <= 4*x && y % 2 == 0) printf("Yes"); else printf("No"); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_213526/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_213526/source.c" target datalayout = "e-m:e-p270: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 s[5], i, n, x, ans; memset(s, 0, sizeof s); scanf("%d", &n); for (i = 0; i < n; i++) { scanf("%d", &x); s[x]++; } ans = s[4]; x = s[1] < s[3] ? s[1] : s[3]; ans += x; s[1] -= x; s[3] -= x; ans += s[2] / 2; s[2] %= 2; if (s[3]) ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_21357/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_21357/source.c" target datalayout = "e-m:e-p270: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 a,b; double c,d; scanf("%d %d",&a,&b); c = (double)a*2-(double)b/2; d = floor(c); if(c == d && 0<=c && a-c>=0){ printf("Yes\n"); }else{ printf("No\n"); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_213612/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_213612/source.c" target datalayout = "e-m:e-p270: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, f; scanf("%d%d", &h, &f); int ashi = h*2; int flag=0; for(int kame = 0; ashi <= f && kame <= h; kame++) { ashi = (h-kame) * 2 + kame * 4; if(ashi==f) flag =1; } if(flag==1) printf("Yes\n"); else printf("No\n"); retu...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_213656/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_213656/source.c" target datalayout = "e-m:e-p270: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 X,Y,t; scanf("%d",&Y); scanf("%d",&X); t=(4*Y-X)/2; if(Y-t>=0&&t>=0&&X%2==0) { puts("Yes"); }else{ puts("No"); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_213706/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_213706/source.c" target datalayout = "e-m:e-p270: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 groups_by_size[5]; int main() { int n; scanf("%d ", &n); int i; for (i = 0; i < n; ++i) { int size; scanf("%d ", &size); ++groups_by_size[size]; } int answer = groups_by_size[4] + groups_by_size[3] + groups_by_size[2] / 2 + groups_by_size...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_21375/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_21375/source.c" target datalayout = "e-m:e-p270: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 x,y; scanf("%d%d",&x,&y); y -= 2 * x; puts(y < 0 || y > 2*x || y % 2 ?"No":"Yes"); }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_213793/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_213793/source.c" target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-pc-linux-gnu" @.str = private unnamed_add...
#include<stdio.h> #include<string.h> int main(void){ char s[7]; scanf("%s",&s); if(strcmp(s,"Sunny")==0){printf("Cloudy");} if(strcmp(s,"Cloudy")==0){printf("Rainy");} if(strcmp(s,"Rainy")==0){printf("Sunny");} return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_213843/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_213843/source.c" target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-pc-linux-gnu" @.str = private unnamed_add...
#include<stdio.h> #include<string.h> int main(){ char S[10]; char *A="Sunny"; char *B="Cloudy"; char *C="Rainy"; scanf("%s",&S); if(strcmp(S,A)==0){ printf("%s",B); }else if(strcmp(S,B)==0){ printf("%s",C); }else if(strcmp(S,C)==0){ printf("%s",A); }else{ printf("error"); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_213900/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_213900/source.c" target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-pc-linux-gnu" @.str = private unnamed_add...
#include<stdio.h> #include<string.h> int main (void){ char S[100]; char *s1 = "Sunny"; char *s2 = "Rainy"; char *s3 = "Cloudy"; scanf("%s",S); if(strcmp(S,s1)== 0){ printf("Cloudy\n"); }else if(strcmp(S,s2)==0){ printf("Su...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_213959/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_213959/source.c" target datalayout = "e-m:e-p270: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.3 = private unnamed_a...
#include <stdio.h> #include <string.h> int main(void) { char S[10]; scanf("%s", S); if(strcmp(S, "Sunny") == 0){ printf("Cloudy\n"); } else if(strcmp(S, "Cloudy") == 0){ printf("Rainy\n"); } else{ printf("Sunny\n"); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_214000/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_214000/source.c" target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-pc-linux-gnu" @.str = private unnamed_add...
#include <stdio.h> int main(void) { char s[6]; scanf("%s", s); if(s[0] == 'S'){ printf("Cloudy"); }else if(s[0] == 'C'){ printf("Rainy"); }else{ printf("Sunny"); } return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_214044/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_214044/source.c" target datalayout = "e-m:e-p270: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 *w[256] = {}; w['S'] = "Cloudy"; w['C'] = "Rainy"; w['R'] = "Sunny"; char s[256]; fgets(s, 256, stdin); puts(w[s[0]]); }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_214101/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_214101/source.c" target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-pc-linux-gnu" @.str = private unnamed_add...
#include<stdio.h> int main(){ char s[11]; scanf("%s",s); if(s[0]=='S')puts("Cloudy"); if(s[0]=='C')puts("Rainy"); if(s[0]=='R')puts("Sunny"); return 0; }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_214145/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_214145/source.c" target datalayout = "e-m:e-p270: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 long long ll; int main(){ char s[20]; scanf("%s",s); if(s[0] == 'S') printf("Cloudy"); if(s[0] == 'C') printf("Rainy"); if(s[0] == 'R') printf("Sunny"); }
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_214196/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_214196/source.c" target datalayout = "e-m:e-p270: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 SIZE10 100000 typedef long long int ll; typedef unsigned char u8; int main(void){ int A = 0, B = 0, C = 0; int N = 0; int sum = 0; char w[10]; scanf("%s", w); if(w[0] == 'S'){ printf("Cloudy"); } else if(w[0] == 'C'){ printf("Rainy"); }...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_214239/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_214239/source.c" target datalayout = "e-m:e-p270: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 cards[128][14]={{0}}; int i,N; scanf("%d",&N); for(i=0;i<N;i++){ char c; int cn; scanf("%c",&c); scanf("%c %d",&c,&cn); cards[c][cn]=1; } for(i=1;i<=13;i++){ if(cards['S'][i]==0){ printf(...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_214297/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_214297/source.c" target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-pc-linux-gnu" @.str = private unnamed_add...
#include <stdio.h> #include <stdlib.h> #include <math.h> int amount[10]; int N; int min(int a,int b) { return (a<b)?a:b; } int main() { scanf("%d",&N); int i; int s; for(i=0;i<N;i++) { scanf("%d",&s); amount[s]++; } int taxis=amount[4]; int three_and_one=min(amount...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_21434/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_21434/source.c" target datalayout = "e-m:e-p270: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 card[4][13]; const char mark[]={'S','H','C','D'}; int main() { int i,j,n; scanf("%d", &n); for(i=0; i<n; i++){ char a; int x; scanf(" %c %d",&a,&x); if(a=='S') card[0][x-1]=1; else if(a=='H') card[1][x-1]=1; else if(a=='C') card[2][x-1]=1; else if(a=='D') card[3][x-1]=1; } fo...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_214426/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_214426/source.c" target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-pc-linux-gnu" @mark = dso_local local_unn...
#include "stdio.h" #include "stdlib.h" #include "string.h" #define Max 20000 int N; int S[Max]; int main() { scanf("%d", &N); int max = 0; int i; for (i = 0; i < N; i++) { scanf("%d", &S[i]); max += S[i]; } int d; for (d = 1; d * d <= N; d++) { if (N % d == 0) { int s, j, sum; int step = N / ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_21447/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_21447/source.c" target datalayout = "e-m:e-p270: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 EGARA 4 #define MAISUU 13 int main(void){ int n; int i, j; int cards[4][14]; char egara; int rank; //initialize for(i=0;i<EGARA;i++){ for(j=1;j<=MAISUU;j++){ cards[i][j]=0; } } //input scanf("%d\n", &n); for(i=0;i<n;i++){ scanf("%c %d\n", &egara, ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_214512/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_214512/source.c" target datalayout = "e-m:e-p270: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 a,S,H,C,D; int i,j,k,n,s[13],h[13],c[13],d[13]; scanf("%d",&n); for(i=0;i<=12;i++) { s[i]=0; h[i]=0; c[i]=0; d[i]=0; } for(j=0;j<=2*n-1;j++) { scanf("%c",&a); if(a=='S') { scanf("%d",&i); s[i-1] = 1; } else if(a=='H') { scanf("%d",&i); h[...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_214556/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_214556/source.c" target datalayout = "e-m:e-p270: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() { int test; scanf("%d\n",&test); int n; for(int i=0;i<test;i++) { int a=0,b=0; scanf("%d\n",&n); a = (2 *(1 - pow(2, n/2-1))) / (-1) + pow(2,n); b = (pow(2,n/2) *(1 - pow(2, n/2))) / (-1) ; if(i==(test-1)) printf("%d",a-b); else ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_2146/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_2146/source.c" target datalayout = "e-m:e-p270: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(void) { int card[4][13] = {}; char symbol; int number; int n; int i, j; scanf("%d", &n); for(i=0; i<n*2; i++){ scanf("%c %d", &symbol, &number); switch(symbol){ case 'S': card[0][number-1] = 1; ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_214642/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_214642/source.c" target datalayout = "e-m:e-p270: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, n; int rec[4][13] = {0}; char mark[4]; int num; scanf("%d", &n); for(i = 0; i < n; i++) { scanf("%s %d", mark, &num); if(mark[0] == 'S') rec[0][num-1]++; if(mark[0] == 'H') rec[1][num-1]++; if(mark[0] == 'C') rec[2][num-1]++; if(mark[0] == ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_214736/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_214736/source.c" target datalayout = "e-m:e-p270: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, k, a[101],winCount, i=0; scanf("%i%i", &n,&k); for (i = 0; i<n; i++) scanf("%i", &a[i]); winCount = a[k-1]; if (a[k-1] >0){ for (i = k-1; i<n&&a[i]==winCount; i++); printf("%i", i); } else { for (i = 0; i<k-1&&a[i]>0; i+...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_21478/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_21478/source.c" target datalayout = "e-m:e-p270: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(){ char *mark = "SHCD"; int card[4][13] = { 0 }; int i, j; int n, t; char c; scanf("%d", &n); for(i = 0; i < n; ++i){ scanf(" %c %d", &c, &t); card[strchr(mark, c) - mark][t - 1] = 1; } for(i = 0; i ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_214822/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_214822/source.c" target datalayout = "e-m:e-p270: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[52] = {0}; char b[4] = {'S','H','C','D'}; int d, n; char c; int e, f; scanf("%d", &n); for (f = 0; f < n; f++) { scanf("%*c%c %d", &c, &d); for (e = 0; b[e] != c; e++) { d += 13; } a[d - 1] = 1; } for (f = 0; f < 4; f++) { for (e = 0; e < 13; e++) ...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_214866/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_214866/source.c" target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-pc-linux-gnu" @__const.main.b = private u...
/* Finding Missing Cards */ #include <stdio.h> int main() { int card[4][14], c, n, i, j; char s; scanf("%d", &n); for(i=0; i<n; i++){ for(j=0;j<2;j++){ scanf("%c %d", &s, &c); } if(s == 'S'){ card[0][c] = c; } else if(s == 'H'){ c...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_214909/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_214909/source.c" target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-pc-linux-gnu" @.str = private unnamed_add...
#include<stdio.h> #include<string.h> #include<stdlib.h> int main(){ int n,a[1000002]={0},i,b[1000002]={0},max=0,d=0,x; char c; scanf("%d",&n); while(n--){ scanf("\n%c %d",&c,&x); if(b[x]==0 && c=='-') max++; else if(c=='-'){ a[x]=0; d--; } else if(c=='+') { b[x]=1; d++; if(d>max) m...
; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_21496/source.c' source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_21496/source.c" target datalayout = "e-m:e-p270: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 ...