Source_Code stringlengths 69 484k | IR_Original stringlengths 2.05k 17.9M |
|---|---|
#include <stdio.h>
int main (void) {
int H, W, i, j;
H = 1; W = 1;
while (H != 0 || W != 0){
scanf("%d %d", &H, &W);
if(H == 0 && W == 0) return 0;
for (i = 0; i < H; i++) {
for (j = 0; j < W; j++) {
if (i == 0 || i == H-1 || j == 0 || j == W-1)printf("#");
else printf(".");
}
pri... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_101297/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_101297/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 int i,j,t,k,n,p=0,ng=0;
long long int ans=0;
scanf("%ld",&n);
long int a[n],b[n];
for(j=0;j<=n-1;j++)
{
scanf("%ld%ld",&a[j],&b[j]);
if(a[j]>0)
p++;
else
ng++;
}
for(i=0;i<=n-2;i++)
{
for(j=i+1;j<=n-1;... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_10134/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_10134/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 MAX 200000
long long int a[40], sum1[41][MAX], sum2[41][MAX], w1[41], w2[41];
int w;
int Input(void);
long long int Inputll(void);
long long int Combi(int w, int k);
int Compare(const void *a, const void *b);
long long int Binary_search(long long int *sum, long long int x, l... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_101390/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_101390/source.c"
target datalayout = "e-m:e-p270: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<string.h>
#include<stdlib.h>
int main(){
char str[21];
int i,j;
char output[21]={'\0'};
int s,t;
s=0;
t=0;
scanf("%s",str);
i = strlen(str);
for(j=0;j<i;j++){
if(str[j]=='A'){
s=1;
}
else if(str[j]=='Z' && s==1){
s=0;
output[t]='A';
output[t+1]='Z';
t=t+2;
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_101440/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_101440/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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, A, B, C, X, ans, cx, i;
int Y[10001];
while (scanf("%d%d%d%d%d", &N, &A, &B, &C, &X) && N) {
ans = 0;
for (int i = 0; i < N; i++)
scanf("%d", &Y[i]);
Y[N] = 10000;
i = 0;
while (N) {
if (ans++ > 10000) {
ans = 0;
break;
}
if (X == Y[i])
i++, N... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_101505/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_101505/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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>
typedef struct E{
int to, len;
struct E *next;
}edge;
int N, d[1<<17];
edge G[1<<17], *nil;
void push(int i, int j, int k){
edge *X = (edge*)malloc(sizeof(edge));
(*X).to = j;
(*X).len = k;
(*X).next = G[i].next;
G[i].next = X;
return;
}
void dfs(int i){
edge *x = G[i].next... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_101549/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_101549/source.c"
target datalayout = "e-m:e-p270: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.E = type { i32, i32... |
#include <stdio.h>
int main(){
int n, p; scanf("%d %d", &n, &p);
int kisu = 0;
for(int i=0; i<n; i++){
int a; scanf("%d", &a);
if(a % 2) kisu++;
}
long ans = ((long)1 << (n-kisu));
long plus;
if(kisu){
plus = ((long)1 << (kisu-1));
}else if(p == 1){
plus = 0;
}else{
plus = ... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_101592/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_101592/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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... |
#define _CRT_SECURE_NO_WARNINGS
#include<stdio.h>
#include<string.h>
int main()
{
long long int n, p, a[101], ou = 0, ji = 0, i, j;
long long int res = 0;
long long int C[55][55], pow[55];
C[0][0] = 1;
pow[0] = 1;
for (i = 1; i <= 50; i++)
pow[i] = pow[i - 1] * 2;
for (i = 0; i <= 50; i++) {
C[i][0] = 1;
C... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_101635/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_101635/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int main(void){
int N;
scanf("%d",&N);
int d[N];
int i,sum,j;
sum=0;
for(i=0;i<N;i++){scanf("%d",&d[i]);}
for(i=0;i<N;i++){for(j=i+1;j<N;j++){sum=sum+(d[i]*d[j]);}}
printf("%d",sum);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_101686/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_101686/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
#include<string.h>
#include<stdlib.h>
#include<math.h>
int main(){
int n,i,j;
int a[51];
int sum = 0;
scanf("%d", &n);
for(i = 0;i < n;i++) scanf("%d", &a[i]);
for(i = 0;i < n - 1;i++){
for(j = i + 1;j < n;j++){
sum += a[i]*a[j];
}
}
printf("%d\n", sum);
return 0;... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_101729/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_101729/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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){
// ((ΣN)² - ΣN²) / 2 を計算する
int a, N;
int i = 0, nSum = 0, squareSum = 0;
scanf("%d", &N);
while(i < N){
scanf("%d", &a);
nSum += a;
squareSum += a * a;
i++;
}
printf("%d\n", (nSum * nSum - squareSum) / 2);
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_101772/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_101772/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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;
scanf("%d",&a);
int b[a];
int i;
for(i=0;i<a;i++){
scanf("%d",&b[i]);
}
int j;
int sum=0;
for(i=0;i<a-1;i++){
for(j=i+1;j<a;j++){
sum = sum+b[i] * b[j];
}
}
printf("%d",sum);
return(0);
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_101815/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_101815/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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=0;
scanf("%d",&n);
int d[n];
int i=0;
int j=0;
char y;
int sum1=0;
int sum=0;
int temp=0;
if(n>=2&&n<=50){
do{
scanf("%d",&d[i]);
i++;
}while(y=getchar()!='\n');
temp=n;
for(i=0;i<n;i++){
for(j=i;j<(temp-1);j++){
sum... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_101859/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_101859/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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[51], d, e, sum = 0;
scanf("%d", &a);
for(b = 0; b < a; b++)
{
scanf("%d", &c[b]);
}
for(d = 0; d < a; d++)
{
for(e = d + 1; e < a; e++)
{
sum += c[d] * c[e];
}
}
printf("%d", sum);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_101945/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_101945/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
#include<stdlib.h>
#include<string.h>
int main(){
int n, d[1000];
int count,ans;
scanf("%d",&n);
for(int i=0;i<n;i++){
scanf("%d",&d[i]);
}
for(int i=0;i<n;i++){
for(int j=i+1;j<n;j++){
ans += d[i]*d[j];
}
}
print... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_101989/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_101989/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <stdlib.h>
int main(void) {
int num,*mat,ans=0,i,j;
scanf("%d",&num);
mat=malloc(sizeof(int)*num);
for (i=0;i<num;i++) {
scanf("%d",&mat[i]);
}
for (i=0;i<num-1;i++) {
for (j=i+1;j<num;j++) {
ans+=mat[i]*mat[j];
}
}
free(ma... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_102030/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_102030/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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
struct node{int p,l,r;};
struct node t[MAX];
int n;
void preparse(int u){
if(u==NIL) return;
printf(" %d",u);
preparse(t[u].l);
preparse(t[u].r);
}
void inparse(int u){
if(u==NIL) return;
inparse(t[u].l);
printf(" %d",u);
inparse(t[u].r);
}
void pos... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_102074/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_102074/source.c"
target datalayout = "e-m:e-p270: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 25
typedef struct{
int p;
int l;
int r;
}Node;
Node T[N];
void preorder(int root){
int i, j;
printf(" %d", root);
if(T[root].l != -1){
i = T[root].l;
preorder(i);
if(T[root].r != -1){
j = T[root].r;
preorder(j);
}
}else{
if(T[root].r != -... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_102117/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_102117/source.c"
target datalayout = "e-m:e-p270: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 NIL -1 /*??????????????????????????????????????????????????\?????????????????????*/
struct Node{
int left;
int right;
int parent;
};
void prewalk(int);
void inorderwalk(int);
void postorderwalk(int);
struct Node inputNodedata[10000];
int main(){
int sumNode,Nodeid,i,j,root,leftda... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_102175/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_102175/source.c"
target datalayout = "e-m:e-p270: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 25
typedef struct {
int parent;
int left;
int right;
} Node;
Node Tree[N];
void printPreorder(int x) {
printf(" %d", x);
if(Tree[x].left != -1)printPreorder(Tree[x].left);
if(Tree[x].right != -1)printPreorder(Tree[x].right);
}
void printInorder(int x) {
if(Tree[x].left != ... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_102232/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_102232/source.c"
target datalayout = "e-m:e-p270: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 200000
#define NIL -1
typedef struct Node {
int parent;
int left;
int right;
} node;
node tree[N];
void preOrder(int u) {
if (u == NIL) {
return;
}
printf(" %d", u);
preOrder(tree[u].left);
preOrder(tree[u].right);
}
void inOrder(int u) {
if (u == NIL) {
return;... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_102283/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_102283/source.c"
target datalayout = "e-m:e-p270: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>
struct tree{
int back, left, right;
};
struct tree a[25];
void preorder(int id){
if (id == -1){
return;
}
printf(" %d", id);
preorder(a[id].left);
preorder(a[id].right);
}
void inorder(int id){
if (id == -1){
return;
}
inorder(a[id].left);
printf(" %d", id);
inorder(a[id].righ... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_102326/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_102326/source.c"
target datalayout = "e-m:e-p270: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>
int main()
{
int a,b,c;
scanf("%d %d %d",&a, &b, &c);
if(a >= b)
{
if(a > b&&a>b+c)
printf("+\n");
else if(a ==b&&c == 0)
printf("0\n");
else
printf("?\n");
}
else
{
if(b > a&&b>a+c)
printf("-\... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_10237/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_10237/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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>
typedef struct _tree_t {
int p, l, r;
} tree_t;
void print_preorder(int depth, tree_t tree[], int id, int n) {
printf(" %d", id);
if(tree[id].l != -1) print_preorder(depth+1, tree, tree[id].l, n);
if(tree[id].r != -1) print_preorder(depth+1, tree, tree[id].r, n);
}
void print_inorder(int depth... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_102412/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_102412/source.c"
target datalayout = "e-m:e-p270: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_t = type { i3... |
#include <stdio.h>
#define MAX(a, b) ((a) > (b) ? (a) : (b))
typedef struct {
int parent;
int left;
int right;
} Node;
Node node[26];
int getSibling(int id) {
int p = node[id].parent;
if (p == -1) return -1;
return node[p].left == id ? node[p].right : node[p].left;
}
int getDegree(int id) {
int cnt ... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_102463/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_102463/source.c"
target datalayout = "e-m:e-p270: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 l,r,par;
} node;
node N[25];
void init(int);
void Preorder(int);
void Inorder(int);
void Postorder(int);
int main(){
int n,i,id,l,r;
int p;
scanf("%d" ,&n);
init(n);
for(i = 0 ; i < n ; i++){
scanf("%d%d%d" ,&id ,&l ,&r);
if(l != -1)... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_102513/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_102513/source.c"
target datalayout = "e-m:e-p270: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_NUM 25
typedef struct Node{
int key;
int left;
int right;
int parent;
}node;
int Root(node *tree,int len){
int i;
for(i=0; i<len; i++){
if(tree[i].key != -1 && tree[i].parent == -1){
return i;
}
}
return -1;
}
void PrintPreorde... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_102557/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_102557/source.c"
target datalayout = "e-m:e-p270: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, ... |
// AOJ ALDS1_7_C Tree Walk
// 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_102607/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_102607/source.c"
target datalayout = "e-m:e-p270: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 <assert.h>
#include <stdlib.h>
#include <string.h>
struct Node {
int id;
int parent;
int left;
int right;
};
static int FindRoot(const struct Node nodes[], int n) {
int i;
for ( i = 0; i < n; i++ ) {
if ( nodes[i].parent == -1 ) {
return i;
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_102650/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_102650/source.c"
target datalayout = "e-m:e-p270: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 NIL -1
#define MAX 100000
typedef struct Node {
int left;
int right;
int p;
} node;
node T[MAX];
int n;
void preParse(int u);
void inParse(int u);
void postParse(int u);
int main(void){
int x;
int l,r;
int i;
int root;
scanf("%d",&n);
for(i = 0;i < n;i++){
T[i].p... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_102694/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_102694/source.c"
target datalayout = "e-m:e-p270: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
#define NIL -1
struct Node{
int left;
int right;
int parent;
};
struct Node Tree[MAX];
void Preorder(int);
void Inorder(int);
void Postorder(int);
int main(){
int n, i;
int id,l,r,root;
scanf("%d",&n);
for(i = 0 ; i < n ; i++){
Tree[i].parent = NIL;
}
fo... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_102737/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_102737/source.c"
target datalayout = "e-m:e-p270: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 10000
#define NIL -1
struct Node{ int p, l, r; };
struct Node T[MAX];
int n;
void preParse(int u){
if( u == NIL ) return;
printf(" %d",u);
preParse(T[u].l);
preParse(T[u].r);
}
void inParse(int u){
if( u == NIL ) return ;
inParse(T[u].l);
printf(" %d",u);
inParse(T[u].r);
}
v... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_102780/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_102780/source.c"
target datalayout = "e-m:e-p270: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 MAX 10000
#define NIL -1
struct Node{
int p, l, r;
};
struct Node T[MAX];
int n;
void preO(int );
void inO(int );
void postO(int );
void preO(int u){
if( u == NIL ) return;
printf(" %d", u);
preO(T[u].l);
preO(T[u].r);
}
void inO(int u){
if( u == NIL) retu... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_102823/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_102823/source.c"
target datalayout = "e-m:e-p270: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
#define NIL -1
struct Node{
int p,l,r;
};
struct Node data[N];
int n;
void preP(int a)
{
if(a == NIL)
return;
printf(" %d",a);
preP(data[a].l);
preP(data[a].r);
}
void inP(int a)
{
if(a == NIL)
return;
inP(data[a].l);
printf(" %d",a);
inP(data[a].r);
}
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_102867/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_102867/source.c"
target datalayout = "e-m:e-p270: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, ... |
//
// main.c
// Task1_20190607
//
// Created by Z on 07.06.19.
// Copyright © 2019 Z. All rights reserved.
//
#include <stdio.h>
#include <stdlib.h>
int main(int argc, const char * argv[]) {
int x,y,z;
scanf("%i %i %i",&x,&y,&z);
int delta1 = x - y;
int delta2 = abs(delta1) - z;
if(delta2 < 0... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_10291/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_10291/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 num,inum,stack[20][2],sp,map[21][21],i,j,step,x,y;
char dir;
while (1) {
scanf("%d\n",&num);
if (num==0) break;
x=10,y=10;
for (i=0; i<=20; i++) {
for (j=0; j<=20; j++) map[i][j]=0;
}
for (sp=0; sp<num; sp++)... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_102968/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_102968/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <stdlib.h>
int main()
{
int x,y,z;
scanf("%d",&x);
scanf("%d",&y);
scanf("%d",&z);
if ((x-y)==0 && z==0)
printf("0");
else if (z>=abs(x-y))
printf("?");
else if
(x>y)
printf("+");
else
printf("-");
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_10301/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_10301/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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>
//30-39
int main()
{
int a, b, valid = 0, counter = 0;
scanf("%d %d", &a, &b);
char str[a+b+1];
scanf("%s", str);
for (int i = 0; i < a + b; i++)
{
if ((30 <= str[i] && str[i]<= 39) || (str[a] == '-'))
{
if (str[i] == '-')
{
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_103053/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_103053/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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(a,b) (a > b ? a : b)
#define MIN(a,b) (a < b ? a : b)
const int inf = 1000000000; // 10^9
int main(){
int a,b;scanf("%d%d",&a,&b);
char s[12];scanf("%s",s);
int flag = 1;
for(int i = 0;i < a;i++){
if(s[i]=='-')flag = 0;
}
/... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_103097/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_103097/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@inf = dso_local local_unna... |
# include <stdio.h>
int main()
{
int n,k;
scanf("%d %d",&n,&k);
if(k>n/2) k=n-k+1;
if(k==n||k==1)
printf("%d",6+3*(n-2));
else
printf("%d",6+3*(k-2)+(k-1)+3*(n-k));
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_10314/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_10314/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 a,b;
scanf("%d %d",&a, &b);
char str[a+b+2];
scanf("%s",str);
int i;
int flag=1;
for (i=0;i<=a+b;i++)
{
if (i==a)
continue;
else
{
if (str[i]>=48 && str[i]<=(57))
flag=1;
else{
flag=0;
break;
}
}
}
if (str[a]!='-')
flag=0;
if (flag==0)
p... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_103190/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_103190/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
#include<string.h>
#include<stdlib.h>
#include<math.h>
//for
#define REP(i,n) for(int i=0,i##_len=(int)(n);i<i##_len;i++)
#define REPS(i,n) for(int i=1,i##_len=(int)(n);i<=i##_len;i++)
#define RREP(i,n) for(int i=(int)(n)-1;i>=0;i--)
#define RREPS(i,n) for(int i=(int)(n);i>0;i--)
//printf
#define PR... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_103240/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_103240/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 argc, char *argv[])
{
char deck[200 + 1];
char tmp[2][200 + 1];
int len;
int m, h, i;
while (1) {
scanf("%s", deck);
if (!strcmp(deck, "-")) break;
len = strlen(deck);
scanf("%d", &m);
for (i = 0; i < m; i++) {
scanf("%d", &h);
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_103291/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_103291/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 card[200],stc[200];
int m,h,length,i,j;
while(1){
scanf("%s",card);
if(card[0] == '-') break;
length = strlen(card);
scanf("%d",&h);
for(m=0;m<h;m++){
scanf("%d",&i);
strncpy(stc,card,i);
stc[i] = '\0';
for(j = 0;j<length-i;j++) car... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_103341/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_103341/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <string.h>
int main(void){
int m, h;
int i, k, len;
char card[201];
scanf(" %s", card);
while(strcmp(card, "-")){
scanf("%d", &m);
len = (int)strlen(card);
k = 0;
for(i = 0; i < m; i++){
scanf("%d", &h);
k = (k + h) % len;
}
for(i = 0; i < len;... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_103385/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_103385/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
#include<ctype.h>
#include<string.h>
#include<math.h>
#include<stdlib.h>
int main(void){
char a[201];
char b[201];
char d[201];
int i,j,c,alen,blen,h;
while(1){
scanf("%s",a);
if(a[0] == '-' ) break;
scanf("%d",&h);
for(j=0;j<h;j++){
scan... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_103428/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_103428/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
#include<string.h>
#define MAXS 200
char s[MAXS];
char qs[MAXS];
void qupop(int shn,int mode,int len){
int i;
if(mode == 1){
for(i = 0;i < shn;i++){
qs[i] = s[i];
}
for(i = shn;i < len;i++){
s[i-shn] = s[i];
}
}
else{
for(... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_103471/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_103471/source.c"
target datalayout = "e-m:e-p270: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 global [200 ... |
#include <stdio.h>
#include <string.h>
int main(void) {
char str[201]={'\0'}, tmp[201]={'\0'};
int m, h, i, j;
while (1) {
scanf("%s", str);
if (!strcmp(str, "-")) break;
scanf("%d", &m);
while (m>0) {
scanf("%d", &h);
for (i=h; str[i]!='\0'; i++) tm... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_103521/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_103521/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 swap(char [],char [],int);
int move(int,int,char []);
void unit(int,char [],char [],int);
int main(void){
int shuffle,i,j,len,time,k,count,loop;
char card[200],temp[200],temp2[1];
for(loop=0;loop>-1;loop++){
scanf("%s",card);
if(card[0]=='-')
bre... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_103565/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_103565/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 m,h, i,j,k;
char card[201] = { 0 }, c1[201] = {0};
scanf("%s", card);
while (1) {
if (card[0] == '-'){
break;
}
scanf("%d", &m);
i = 0;
while(i<m) {
scanf("%d", &h);
for (j = h,k=0; j<strlen(card); j++,k++) {
c1[k] = card[j];
}
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_103608/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_103608/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 A[200];
int h,i,j,m,n;
char t;
scanf("%s",A);
n=strlen(A);
while (A[0]!='-'){
scanf("%d",&m);
for (i=0;i<m;i++){
scanf("%d",&h);
while(h-->0){
t=A[0];
for (j=1;j<n;j++){
A[j-1]=A[j];
}
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_103651/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_103651/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 ch[250]={0};
char a[250] ={0};
int h;
int i,j,k,l,n,m;
while(1){
i=0;
while(1){
scanf("%c",&ch[i]);
if(ch[i] == '\n') {
break;
}
i++;
}
if ( i == 1 && ch[0] == '-' ) break;
scanf("%d",&m)... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_103695/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_103695/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 A[200];
int h,i,j,m,n;
char t;
scanf("%s",A);
n=strlen(A);
while (A[0]!='-'){
scanf("%d",&m);
for (i=0;i<m;i++){
scanf("%d",&h);
while(h-->0){
t=A[0];
for (j=1;j<n;j++){
A[j-1]=A[j];
}
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_103745/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_103745/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <stdlib.h>
int main()
{
int n, k;
scanf("%d %d",&n,&k);
int i,m;
if(n%2==0){
if(k<=n/2)
m= (n-1)*3+2*1+k;
else
m= (n-1)*3+2*1+(n+1-k);
}
else{
if(k<=(n/2+1))
m= (n-1)*3+2*1+k;
else
m= (n-... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_10381/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_10381/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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>
#include <inttypes.h>
int cmp(const void* x, const void* y) {
int64_t a = *(const int64_t*)x, b = *(const int64_t*)y;
return a > b ? -1 : a < b;
}
int N;
int64_t M;
int64_t A[114514];
int64_t A_ruiseki[114514];
/* target以上の要素の数を求める、ついでに和も求める */
int64_t ge_count(int64_t* sum, ... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_103853/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_103853/source.c"
target datalayout = "e-m:e-p270: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(){
int N,frag = 0,Nfrag = 0;
scanf("%d",&N);
int a[N];
for (int i = 0; i < N; i++)
{
scanf("%d",&a[i]);
}
while(frag == 0){
for (int i = 0; i < N; i++)
{
if(a[i] % 2 == 1){
frag = 1;
}
}
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_103897/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_103897/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 <float.h>
#define i_cin(X) scanf("%d", &X)
#define i_cin2(X,Y) scanf("%d %d",&X,&Y)
#define i_cin3(X,Y,Z) scanf("%d %d %d",&X,&Y,&Z)
#define l_cin(X) scanf("%ld",&X)
#define f_cin(X) scanf("%f",&X)
#define l_cin2(X,Y) scanf("%ld %l... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_103947/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_103947/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
#include <math.h>
int main(void){
int N;
int counter,num;
int min=10000;
scanf("%d",&N);
for (counter=1; counter<=N; counter++) {
scanf("%d",&num);
int d=0;
while(num%2 ==0){
num /=2;
++d;
}
if(min>d)
min=d;
}
printf("%d\n", min);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_103990/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_103990/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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, r=1<<29;
for (scanf("%d",&n); n--;) {
int a, c = 0;
for (scanf("%d",&a); a%2<1; a/=2) ++c;
r = r>c?c:r;
}
printf("%d\n", r);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_104032/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_104032/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 n,i,a[300],x=0,ans=0;
scanf("%d",&n);
for(i=0;i<n;++i){
scanf("%d",&a[i]);
}
while(1){
for(i=0;i<n;++i){
if(a[i]%2==0)
a[i]/=2;
else{
printf("%d",ans);
return 0;
}
}
ans++;
}
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_104076/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_104076/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int min(int a, int b){return a>b?b:a;}
int n, i;
int a;
int ans, now;
int main(){
ans = 16384;
scanf("%d", &n);
for(i=0; i<n; i++){
scanf("%d", &a);
now=0;
while(!(a&1)){a>>=1; now++;}
ans = min(now, ans);
}
printf("%d\n", ans);
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_104119/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_104119/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@ans = dso_local local_unna... |
#include <stdio.h>
int main(void)
{
int min = 1000000001;
int N;
int a[201];
int i, tmp;
scanf("%d", &N);
for ( i=0; i<N; i++ ) {
tmp = 0;
scanf("%d", &a[i]);
while ( a[i] > 0 && a[i] % 2 == 0 ) {
a[i] >>= 1;
tmp++;
}
if ( min > tmp ) {
min = tmp;
}
}
printf("... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_104162/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_104162/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 b,n,a[201],count=0,temp=2,i;
scanf("%d",&n);
for(i=0;i<n;i++){
scanf("%d",&b);
if(b%2==1) count++;
a[i]=b;
}
if(count!=0) printf("0\n");
else{
count=0;
while(temp%2==0){
for(i=0;i<n;i++){
a[i]=... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_104212/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_104212/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 <math.h>
#include <stdlib.h>
int main() {
int long long n,i,d=0,e=0,m=100000000000;
scanf("%lld ",&n);
int long long a[n];
for(i=0;i<n;i++)
{
scanf("%lld ",&a[i]);
if(a[i]%2==0)
d++;
while(a[i]%2==0)
{
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_104256/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_104256/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 a[10000];
int b[10000];
int main()
{
int i,j,n=0,m=0,o;
scanf("%d",&j);
for(;j>0;j--)
{
m=0;n=0;
scanf("%d",&o);
for(;o>0;o--)
{
scanf("%d",&i);
if(i%2==0)
{
b[n]=i;
n++;
}
else
{
a[m]=i;
m++;
}
}
for(i=0;i<m;i++)
printf("%d ",a[i]);
for(i=0;i<n;i++)
printf("%d ",b... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_1043/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_1043/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 <string.h>
#include <math.h>
#define rep(i, n) for(i=0;i<(int)(n);i++)
#define max(a, b) ((a) > (b) ? (a) : (b))
#define min(a, b) ((a) < (b) ? (a) : (b))
#define bit(n) (1LL<<(n))
int gcd(int a,int b){return b?gcd(b,a%b):a;}
int lcm(int a,int b){return (a*b)/gcd(a,b);}
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_104342/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_104342/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@dx = dso_local local_unnam... |
#include <stdio.h>
int main(void){
int n,i;
scanf("%d",&n);
int a[n];
for(i=0;i<n;i++) scanf("%d",&a[i]);
int max = a[0];
for(i=1;i<n;i++){
if(max>a[i]+1){
printf("No");
return 0;
}
if(max<a[i]) max = a[i];
}
printf("Yes");
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_104393/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_104393/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int n, h[100001], i, x = 0;
int main()
{
scanf("%d", &n);
for (i = 0; i < n; i++) {
scanf("%d", &h[i]);
if (i > 0 && h[i] > h[i - 1]) {
h[i]--;
}
if (h[i] < h[i - 1]) {
x++;
}
}
if (x == 0) {
printf("Yes\n");
}
else {
printf("No\n");
}
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_104436/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_104436/source.c"
target datalayout = "e-m:e-p270: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 local_unname... |
#include <stdio.h>
int main(void) {
int t;
scanf("%d", &t);
int n, a[100];
for (int i = 0; i < t; ++i) {
scanf("%d", &n);
for (int j = 0; j < n; ++j) {
scanf("%d", &a[j]);
}
for (int j = 0; j < n; j +=2) {
printf("%d %d ", a[j+1], -a[j]);
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_10448/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_10448/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_addr ... |
# include <stdio.h>
# include <stdlib.h>
int main()
{
int times;
scanf("%d",×);
while (times--)
{
int n;
scanf("%d",&n);
int i;
int *a;
int *b;
a=(int*)malloc(n*sizeof(int));
b=(int*)malloc(n*sizeof(int));
for (i=0;i<n;i++)
{
scanf("%d",&a[i]);
}
for (i=0;i<n;i+=2)
{
b[i]=a[i+... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_10453/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_10453/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 ... |
//set many funcs template
//Ver.20190714
#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_104580/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_104580/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
%struct.sd = type { i32, i3... |
#include <stdio.h>
int main() {
char c;
scanf("%c", &c);
if (c == 'a' || c == 'e' || c == 'i' || c == 'o' || c == 'u') printf("vowel\n");
else printf("consonant\n");
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_104623/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_104623/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 c;
scanf("%c", &c);
int aiueo = c == 'a' || c == 'i' || c == 'u' || c == 'e' || c == 'o';
puts(aiueo == 1 ? "vowel" : "consonant");
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_104689/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_104689/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 c[10];
scanf("%s", c);
if(c[0]=='a' || c[0]=='i' || c[0]=='u' || c[0]=='e' || c[0]=='o')
printf("vowel\n");
else
printf("consonant\n");
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_104739/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_104739/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <limits.h>
#include <math.h>
#define MAX 50002;
int main()
{
char arr[100001];
long int i;
scanf("%s",arr);
long int n = strlen(arr);
for(i=0;i<n;i++)
{
printf("%c",arr[i]);
}
for(i=n-1;i>=0;i--)
{
p... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_10479/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_10479/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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>
#include<string.h>
int main()
{
char ch[10000001];
scanf("%s",ch);
int i;
printf("%s",ch);
for(i=strlen(ch)-1;i>=0;i--)
{
printf("%c",ch[i]);
}
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_10484/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_10484/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 c;
scanf("%c",&c);
if(c=='a' || c=='i' || c=='u' || c=='e' || c=='o'){
printf("vowel\n");
} else{
printf("consonant\n");
}
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_104883/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_104883/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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;
scanf("%c",&a);
if(a=='a'||a=='i'||a=='u'||a=='e'||a=='o') printf("vowel\n");
else printf("consonant\n");
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_104926/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_104926/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <string.h>
int main (void) {
int i, l;
char s[1000000];
scanf("%s", s);
l = strlen(s);
printf("%s", s);
for( i=l-1; i>=0; i--) printf("%c", s[i]);
printf("\n");
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_10497/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_10497/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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;
scanf("%d", &n);
if(n % 2 == 0)
printf("%d\n", n);
else
printf("%d\n", n * 2);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_105011/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_105011/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
int main()
{
long long int a,b,n;
while(~scanf("%lld",&a))
{
if(a%2==0)
printf("%lld\n",a);
if(a%2!=0)
printf("%lld\n",2*a);
}
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_105055/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_105055/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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);
if (N % 2)
printf("%d\n", N * 2);
else
printf("%d\n", N);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_105105/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_105105/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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);
if(n%2==0) printf("%d",n);
else printf("%d",2*n);
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_105149/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_105149/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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>
//smallest num which can be devided by 2 and N
int main(void){
int N,i=0;
scanf("%d",&N);
if(N%2 == 0){
printf("%d\n",N);
}
else{
printf("%d\n",2*N);
}
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_105192/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_105192/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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);
if(n%2==0)
printf("%d",n);
else
printf("%d",n*2);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_105242/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_105242/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int main(void)
{
int N;
scanf("%d",&N);
int b=2;
int r,tmp;
int x=N*b;
if(N<b){
tmp=N;
N=b;
b=tmp;
}
r=N%b;
while(r!=0)
{
N=b;
b=r;
r=N%b;
}
printf("%d",x/b);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_105293/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_105293/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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);
if ( n % 2 ) {
printf("%d\n", n * 2);
} else {
printf("%d\n", n);
}
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_105343/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_105343/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 <inttypes.h>
int main(void) {
int64_t W, H, x, y;
if (scanf("%" SCNd64 "%" SCNd64 "%" SCNd64 "%" SCNd64, &W, &H, &x, &y) != 4) return 1;
printf("%" PRId64 ".%d %d\n", W * H / 2, (W * H) % 2 == 0 ? 0 : 5, x * 2 == W && y * 2 == H);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_105394/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_105394/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 W, H, x, y;
scanf("%d %d %d %d", &W, &H, &x, &y);
double res;
res=(double)W*(double)H/(double)2.0;
printf("%lf", res);
if(W%2==0&&H%2==0&&x==W/2&&y==H/2){
printf(" %d", 1);
}
else{
printf(" %d", 0);
}
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_105437/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_105437/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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(){
double w,h,x,y;
scanf("%lf %lf %lf %lf",&w,&h,&x,&y);
if(x==w/2.0 && y == h/2.0){
printf("%lf 1",0.5*w*h);
}
else{
printf("%lf 0",0.5*w*h);
}
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_105480/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_105480/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
int main(void){
double W,H,x,y;
double constant;
scanf("%lf %lf %lf %lf",&W,&H,&x,&y);
//printf("%lld,%lld %lld %lld",W/2,x,H/2,y);
constant=W*H;
if ((x==W/2)&&(y==H/2)){
printf("%f 1\n",constant/2);
}
else... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_105523/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_105523/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <math.h>
int main(){
int w, h, x, y;
double s;
scanf("%d %d %d %d", &w, &h, &x, &y);
s = w * (double)h / 2.0;
printf("%.11lf ", s);
if(w / 2.0 == (double)x && h / 2.0 == (double)y)
printf("1");
else
printf("0");
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_105567/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_105567/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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;
scanf("%d",&N);
int a[N];
for (int i = 0; i < N; i++){
scanf("%d",&a[i]);
}
int br=0,num=1;
for (int i = 0; i < N; i++){
a[i]==num ? num++ : br++;
}
br==N ? puts("-1") : printf("%d",br);
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_105617/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_105617/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 <limits.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
int main(void){
int n, i;
int a=1;
scanf("%d", &n);
for(i=0; i<n; i++){
int A;
scanf("%d", &A);
if(A==a) a++;
}
printf("%d\n", a==1?-1:n-a+1);
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_105660/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_105660/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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,check,ans,A[200000];
check=0;
scanf("%d",&N);
for(i=0;i<N;i++)
scanf("%d",&A[i]);
for(i=0;i<N;i++)
if(A[i]==check+1)
check=check+1;
if(check==0)
printf("-1\n");
else{
ans=N-check;
printf("%d\n",ans);
}
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_105710/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_105710/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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... |
//#define NDEBUG
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
#include <assert.h>
// for DEBUG {{{
#ifdef NDEBUG
#define DEBUG_PRINT(fmt, ...) ((void)0)
#else
#define DEBUG_PRINT(fmt, ...) fprintf(stderr, fmt, ##__VA_ARGS__)
#endif
#define ASSERT_RANGE(min,x,max) assert(((x)>=(min)) &&... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_105754/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_105754/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@stdin = external local_unn... |
#include<stdio.h>
int main()
{
int n;
scanf("%d", &n);
int i;
int a[200005];
for (i = 0; i < n; i++)
scanf("%d", &a[i]);
int c = 1;
for (i = 0; i < n; i++)
{
if (a[i] == c)
c++;
}
if (c == 1)
printf("-1\n");
else
printf("%d\n", n - c + 1);
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_105798/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_105798/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
//set many funcs template
//Ver.20190820
#include<stdio.h>
#include<string.h>
#include<stdlib.h>
#include<stdbool.h>
#include<time.h>
#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_105855/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_105855/source.c"
target datalayout = "e-m:e-p270: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.mkj = type { i64, i... |
#include <stdio.h>
int main(void){
// Your code here!
int n;
scanf("%d",&n);
printf("%d\n",n*n*n);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_105899/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_105899/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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;
scanf("%d",&x);
printf("%d\n",x*x*x);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_105941/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_105941/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.