Source_Code stringlengths 69 484k | IR_Original stringlengths 2.05k 17.9M |
|---|---|
#include <stdio.h>
#include <string.h>
char dict[30600000];
char word[26];
long encode(const char *key){
int n=strlen(key),i;
long sum=0;
long keta=1;
for(i=0;i<n;i++){
int keyi=key[i];
sum = sum + keta * word[keyi];
keta=keta*5;
}
return (sum);
}
void insert(const char *key2) {
long key=e... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_245978/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_245978/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@word = dso_local local_unn... |
#include <stdio.h>
#include <string.h>
typedef long long ll;
int main (void)
{
ll a,b,x,y;
ll n;
scanf("%lld",&n);
while (n--) {
scanf("%lld %lld %lld %lld",&x,&y,&a,&b);
ll dis=y-x;
if (dis<0) dis=-dis;
if (dis%(a+b)==0) {
printf ("%lld\n",dis/(a+b));
}else {
printf ("-1\n");
}
}
return 0;
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_24602/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_24602/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_addr ... |
#include<stdio.h>
#include<string.h>
#define M 1046527
#define L 14
char H[M][L]; /* Hash Table */
int getChar(char ch){
if ( ch == 'A') return 1;
else if ( ch == 'C') return 2;
else if ( ch == 'G') return 3;
else if ( ch == 'T') return 4;
}
/* convert a string into an integer value */
long long getKey(char... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_246063/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_246063/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@H = dso_local global [1046... |
#include<stdio.h>
#include<stdlib.h>
#include<string.h>
#define HASH_M 9973
#define HASH_A 128
#define STR_SIZE 16
typedef struct DATA{
struct DATA *next;
char str[STR_SIZE];
}Data;
Data dlist[HASH_M]; //?????????????´?????????????????????????
int getHashAddr(char str[STR_SIZE], int M, int a){
int i = 0, h = 0;
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_246106/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_246106/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
%struct.DATA = type { ptr, ... |
#include <stdio.h>
int main(void)
{
int t, x, y, a, b;
scanf("%d", &t);
while(t--){
scanf("%d %d %d %d",&x,&y,&a,&b);
if( x<y&&(y-x)%(a+b)==0 )
printf("%d\n", (y-x)/(a+b));
else
printf("-1\n");
}
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_24615/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_24615/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_addr ... |
#include<stdio.h>
#include<string.h>
#define M 1000000
#define L 14
char H[M][L]; /* Hash Table */
int getChar(char ch){
if ( ch == 'A') return 1;
else if ( ch == 'C') return 2;
else if ( ch == 'G') return 3;
else if ( ch == 'T') return 4;
}
/* convert a string into an integer value */
long long getKey(char... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_246193/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_246193/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@H = dso_local global [1000... |
#include<stdio.h>
#include<string.h>
#define M 1031555/* your task*/
#define L 14
char H[M][L]; /* Hash Table */
int getChar(char ch){
if ( ch == 'A') return 1;
else if ( ch == 'C') return 2;
else if ( ch == 'G') return 3;
else if ( ch == 'T') return 4;
}
/* convert a string into an integer value */
long lo... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_246236/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_246236/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@H = dso_local global [1031... |
#include<stdio.h>
#include<stdlib.h>
int main()
{
long long int x,y,a,b,m,n,t;
scanf("%lld",&t);
while(t--){
scanf("%lld %lld %lld %lld",&x,&y,&a,&b);
m=a+b;
n=abs(y-x);
if(n%m==0){
printf("%lld\n",n/m);
}
else{
printf("-1\n");
}
}
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_24628/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_24628/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_addr ... |
#include<stdio.h>
#include<string.h>
#define M 1046527
#define NIL (-1)
#define L 14
char H[M][L];
int getChar(char ch){
if(ch == 'A') return 1;
else if(ch == 'C') return 2;
else if(ch == 'G') return 3;
else if(ch == 'T') return 4;
else return 0;
}
long long getKey(char str[]){
long long sum = 0, p = 1,... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_246322/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_246322/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@H = dso_local global [1046... |
#include<stdio.h>
#include<string.h>
#define M 1000000 /* your task*/
#define NIL (-1)
#define L 14
char H[M][L]; /* Hash Table */
int getChar(char ch){
if ( ch == 'A') return 1;
else if ( ch == 'C') return 2;
else if ( ch == 'G') return 3;
else if ( ch == 'T') return 4;
}
/* convert a string into an integ... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_246388/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_246388/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@H = dso_local global [1000... |
#include<stdio.h>
#include<string.h>
#define M 1000000
#define L 14
char H[M][L]; /* Hash Table */
int getChar(char ch){
if ( ch == 'A') return 1;
else if ( ch == 'C') return 2;
else if ( ch == 'G') return 3;
else if ( ch == 'T') return 4;
}
/* convert a string into an integer value */
long long getKey(char... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_246438/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_246438/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@H = dso_local global [1000... |
#include <stdio.h>
#include <string.h>
#define M 1046257
#define NIL (-1)
#define L 14
char H[M][L];
/* 文字から数値に変換 */
int getChar(char ch) {
if ( ch == 'A' ) return 1;
else if ( ch == 'C' ) return 2;
else if ( ch == 'G' ) return 3;
else if ( ch == 'T' ) return 4;
return 0;
}
/* 文字列から数値へ変換して key を生成する */
lo... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_246481/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_246481/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@H = dso_local global [1046... |
#include <stdio.h>
#include <string.h>
#define M 1046527
#define L 14
#define NIL (-1)
char H[M][L];
int getChar(char alg)
{
if(alg=='A')return 1;
else if(alg=='C')return 2;
else if(alg=='G')return 3;
else if(alg=='T')return 4;
}
long long getKey(char moji[])
{
long long sum=0,p=1,i;
for(i=0;i<strlen(moji);i++)
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_246524/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_246524/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@H = dso_local global [1046... |
#include<stdio.h>
#include<string.h>
#define MAX 10000000
#define LEN 12
int n;
char dic[MAX][LEN];
long long makekey(char *str){
long long k=0,p=1,i;
int len=strlen(str);
for(i=0;i<len;i++){
if(str[i]=='A') k+=1*p;
else if(str[i]=='C') k+=2*p;
else if(str[i]=='G') k+=3*p;
else if(str[i]=='T') k+... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_246568/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_246568/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@dic = dso_local global [10... |
#include <stdio.h>
#include <string.h>
#define M 1000000
char H[M][20];
int toi(char c){
if(c=='A')return 1;
else if(c=='C')return 2;
else if(c=='G')return 3;
else if(c=='T')return 4;
else return 0;
}
long long int gkey(char *str){
long long int sum =0,p=1,i,s;
s=strlen(str);
for(i=0;i<s;i++){
sum... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_246610/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_246610/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@H = dso_local global [1000... |
#include<stdio.h>
#include<string.h>
#define M 1046527
#define L 14
char H[M][L];
int getChar(char ch){
if(ch=='A') return 1;
else if(ch=='C') return 2;
else if(ch=='G') return 3;
else if(ch=='T') return 4;
else return 0;
}
long long getKey(char str[]){
long long sum=0,p=1,i;
for(i=0;i<strlen(str);i++){
su... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_246654/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_246654/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@H = dso_local global [1046... |
#include <stdio.h>
#include <string.h>
int c2i(char c){
if(c=='A')return 1;
else if(c=='C')return 2;
else if(c=='G')return 3;
else if(c=='T')return 4;
return 0;
}
int makekey(char str[]){
long sum=0,p=1,i;
for(i=0;i<strlen(str);i++){
sum+=p*c2i(str[i]);
p*=5;
}
retu... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_246704/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_246704/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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>
#define MAX 1000040
const int m = 1000033;
//const int m2= 1000003;
//7069 - 60
char stack[MAX][15];
int h1(long long);
int h2(long long);
int insert(long long,int);
long long sti(char *);
int main(){
int val,i,j,n,dic=0,dicc=MAX,index2=0,vall;
char op... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_246748/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_246748/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@m = dso_local local_unname... |
#include<stdio.h>
#include<string.h>
#define N 1000000
#define L 14
char H[N][L];
int judge(char x);
int Key(char str[]);
int h1(int key);
int h2(int key);
int search(char str[]);
int insert(char str[]);
int main(void){
int i,n;
int h;
char com[9],str[L];
for(i = 0;i < N;i++){
H[i][0] = '\0';
}
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_246799/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_246799/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@H = dso_local global [1000... |
#include<stdio.h>
#include<string.h>
#define M 1000000
#define L 14
char H[M][L]; /* Hash Table */
int getChar(char ch){
if ( ch == 'A') return 1;
else if ( ch == 'C') return 2;
else if ( ch == 'G') return 3;
else if ( ch == 'T') return 4;
}
/* convert a string into an integer value */
long long getKey(char... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_246849/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_246849/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@H = dso_local global [1000... |
#include<stdio.h>
#include<string.h>
#define M 1128979
#define S 20
char T[M][S];
void insert(long num ,char ch[]){
int i;
int h1 = num % M;
int h2 = 1 + (num % (M-1));
int h;
i=0;
while(i<M){
h = (h1 + i * h2)%M;
if(T[h][0]=='\0'){
strcpy(T[h],ch);
br... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_246942/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_246942/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@T = dso_local global [1128... |
#include <stdio.h>
int main(void)
{
int n;
int age;
int a_g[7] = {0};
int i;
while (1) {
scanf("%d", &n);
if (n == 0) {
break;
}
else {
for (i = 0; i < n; i++) {
scanf("%d", &age);
if ((age >= 0) && (age <= 9)) {
a_g[0]++;
}
else if ((age >= 10) && (age <=... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_246993/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_246993/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 y[7];
int i,n,d;
for(;;){
scanf("%d",&n);
if(n==0)
break;
for(i=0;i<7;i++)
y[i]=0;
for(i=0;i<n;i++){
scanf("%d",&d);
d=d/10;
if(d>=7)
y[6]++;
else
y[d]++;
}
for(i=0;i<7;i++)
printf("%d\n",y[i]);
}
r... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_247042/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_247042/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 compare_int(const void *a, const void *b){
return *(int*)a - *(int*)b;
}
int main(void){
int n;
int a[100000+5];
scanf("%d", &n);
for(int i=0; i<n; i++)scanf("%d", &a[i]);
qsort(a, n, sizeof(int), compare_int);
int ans=0;
int ptr=0;
w... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_247093/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_247093/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 asc(const void *a, const void *b){
long *A = (long *)a;
long *B = (long *)b;
if(*A > *B)
return 1;
if(*A < *B)
return -1;
return 0;
}
int main(){
int N, i, cnt=0, tag=0, ans=0;
long int a[100010];
scanf("%d", &N);
for(i... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_247143/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_247143/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 cmp(const void *a, const void *b){
return *(const int *)a - *(const int *)b;
}
int main(){
int N,A[100000];
int cnt,i;
cnt = 0;
scanf("%d",&N);
for(i=0;i<N;i++){
scanf("%d",&A[i]);
}
A[N]=0;
qsort(A,N,sizeof(int),cmp);
cnt = ... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_247194/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_247194/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int main(){
int n;
int i,j;
int p;
int point;
int s[100] = {0};
for(j = 0;;j++){
point = 0;
do{
scanf("%d",&n);
}while(n % 4 != 0);
if(n == 0){break;}
for(i = 0; i < n/4; i++){
scanf("%d",&p);
point += p;
}
s[j] = point;
}
for(i = 0; i < j; i++){
p... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_247237/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_247237/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#define N 4
int main(){
int i,n;
while (scanf("%d",&n)){
if (n==0)
break;
int t,cnt=0;
for (i=0;i<n/N;i++){
scanf("%d",&t);
cnt+=t;
}
printf("%d\n",cnt);
}
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_247301/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_247301/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 compare(const void *a, const void *b)
{
return *(int *)b - *(int *)a;
}
int main()
{
int na= 0;
int i;
int a[200010];
int b= 0;
printf("\n");
scanf("%d", &na);
for(i=0; i<na; i++)
{
scanf("%d", &a[i])... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_247345/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_247345/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str.1 = private unnamed_a... |
#include <stdio.h>
#include <stdlib.h>
int cmpfunc (const void * a, const void * b) {
return ( *(int*)a - *(int*)b );
}
int main() {
long int n;
scanf("%ld", &n);
long int num[n];
for(long int i=0; i<n; i++) {
scanf("%ld", &num[i]);
}
qsort(num, n, sizeof(long int), cmpfunc);
for(long int i=0; i<... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_247396/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_247396/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 compare_int(const void *a, const void *b)
{
return *(int*)a - *(int*)b;
}
int main(){
int n;
scanf("%d",&n);
int s[n];
for(int i=0;i<n;i++){
scanf("%d",&s[i]);
}
qsort(s, n, sizeof(int), compare_int);
/*for(int i=0;i<n;i++){
printf("%d ",s[i]);
}*/
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_247439/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_247439/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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){
static char A[1000000010];
int N;
int num;
int ans;
scanf("%d",&N);
for(int i=0;i<1000000010;i++){
A[i]=0;
}
for(int i=0;i<N;i++){
scanf("%d",&num);
A[num]++;
if(A[num]>1){
printf("NO");... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_247482/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_247482/source.c"
target datalayout = "e-m:e-p270: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.A = internal unnamed_... |
#include <stdio.h>
int isPrimeNumber(int target_number);
int main ( void ) {
int target_number = 0;
int loop = 0;
int Max_number = 0;
int number_of_prime_numbers = 0;
int flag_not_prime_number = 0;
scanf ( "%d", &Max_number );
for ( loop = 0; loop < Max_number; loop++ ) {
scanf ( "%d", &target_number );
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_247532/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_247532/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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>
#define MAX 10000
int main(){
int x[MAX], n, i, j;
int count = 0;
scanf("%d", &n);
for(i = 0; i < n; i++) scanf("%d", &x[i]);
for(i = 0; i < n; i++){
if((x[i] == 2 || x[i] % 2 == 1) && x[i] != 1){
for(j = 3; j <= sqrt(x[i]); j += 2){
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_247576/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_247576/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 num[10000];
int main( void )
{
int n;
scanf( "%d", &n );
int i, j;
int cnt = n;
for( i=0; i<n; i++ ) {
scanf( "%d", &num[i] );
}
for( i=0; i<n; i++ ) {
if( 2 == *(num+i) ) { continue; }
if( 0 == *(num+i)%2 ... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_247677/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_247677/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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>
#define false 0
#define true 1
int isprime(int);
static const int N = 10000;
int main(){
int n, i, j, count=0;
int A[N];
scanf("%d", &n);
for(i=0;i<n;i++){
scanf("%d", &A[i]);
}
for(i=0;i<n;i++){
if(isprime(A[i])== 1) count++;
}
printf("%d\n", ... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_247727/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_247727/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 gcd(int);
int main() {
int i, n, pn[10000], count = 0;
scanf("%d", &n);
for(i = 0;i < n;i++) {
scanf("%d",&pn[i]);
if(pn[i] == 2) count++;
else if(pn[i] % 2 == 0) continue;
else count += gcd(pn[i]);
}
printf("%d\n",count);
return 0;
}
int gcd(i... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_247770/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_247770/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 x[10000000];
int main(){
int n,i,j,count=0,f=0;
scanf("%d",&n);
for(i=0;i<n;i++){
scanf("%d",&x[i]);
}
for(i=0;i<n;i++){
if(x[i]==1) continue;
if(x[i]==2){
count++;
continue;
}
if(x[i]%2==0) continue;
else {
for(j=2;... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_247813/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_247813/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <math.h>
#include <stdio.h>
int isprime(long x){
int i;
if(x==2) return 1;
if(x<2 || (x%2)==0) return 0;
for(i=3; i<=sqrt(x); i+=2){
if(x%i==0)return 0;
}
return 1;
}
int main(void){
long x;
int n;
int i,cnt=0;
scanf("%d",&n);
for(... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_247857/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_247857/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int main()
{
int a,b,c,i,k;
scanf("%d%d%d",&a,&b,&c);
for(i=a;i>=0;i--)
{
if(b>=(2*i) && c>=(4*i)){
k=7*i;
break;
}
}
printf("%d\n",k);
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_24790/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_24790/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 isprime(int);
int main()
{
int n, i, j, count=0, p[10000];
scanf("%d",&n);
for( i=0 ; i<n ; i++ ){
scanf("%d",&p[i]);
count += isprime(p[i]);
}
printf("%d\n",count);
return 0;
}
int isprime(int x)
{
int i;
if(x==2) return 1;
if(x<2 || x%2==0) retur... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_247943/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_247943/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 a[10000], b=0, n, i, j, m=0, z;
scanf("%d", &n);
for(i = 0 ; i < n ; i++) {
scanf("%d", &a[i]);
}
for(i = 0 ; i < n ; i++) {
z = (double)sqrt(a[i]);
for(j = 2 ; j <= z ; j++) {
if(a[i] % j == 0) {
b++;
break;
}
}
if(b ... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_247987/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_247987/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 isprime(int);
int main(){
int n, a, i, b;
int count=0;
scanf("%d", &n);
for(i = 0; i < n; i++){
scanf("%d", &a);
b = isprime(a);
if(b == 1)
count++;
}
printf("%d\n", count);
return 0;
}
int isprime(int x){
int i;
if(x == 2)
return 1... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_248036/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_248036/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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,p,q,r,d;
scanf("%d%d%d",&a,&b,&c);
p=a;
q=b/2;
r=c/4;
if(p<=q)
{
if(p<=r)
d=p;
else
d=r;
}
if(q<=p)
{
if(q<=r)
d=q;
else
d=r;
}
int e=d+d*2+d*4;
printf("%d",e);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_24808/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_24808/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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 n;
while(scanf("%d",&n)!=EOF)
{
int i,j,t,m,k,count=0;
for(i=0; i<n; i++)
{
scanf("%d",&j);
m=sqrt(j);
k=1;
for( t= 2; t<=m; t++)
if(j%t==0)
k=0;
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_248122/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_248122/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 isPrime(int x)
{
if(x == 2) {
return 1;
}
if(x < 2 || x % 2 == 0) {
return 0;
}
int i = 3;
while(i <= sqrt(x)) {
if(x % i == 0) {
return 0;
}
i = i + 2;
}
return 1;
}
int main(void){
int i,... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_248173/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_248173/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 IsPrime(int);
int main() {
int i,count=0,n,*sosu;
scanf("%d",&n);
sosu = (int *)malloc(n * sizeof (int));
for(i=n-1;i>=0;i--){
scanf("%d",&sosu[i]);
if(IsPrime(sosu[i]) == 1) count++;
}
printf("%d\n",count);
return 0;
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_248216/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_248216/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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() {
static long long a,b,x,y,n,v;
double t,mint;
scanf("%lld%lld%lld",&a,&b,&n);
mint = 1000000009;
while(n--){
scanf("%lld%lld%lld",&x,&y,&v);
t= sqrt((a-x)*(a-x)+(b-y)*(b-y))/v;
if(t<mint)
mint = t;
}
printf("%lf",mint);
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_24826/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_24826/source.c"
target datalayout = "e-m:e-p270: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.a = internal global i64... |
#include<stdio.h>
#include<math.h>
double f= 1000000000,x,y,kx,ky,v,t;
int main(){
scanf("%lf%lf",&x,&y);
int n;
scanf("%d",&n);
while(n--){
scanf("%lf%lf%lf",&kx,&ky,&v);
t=(sqrt((kx-x)*(kx-x) + (ky-y)*(ky-y)))/v;
if(t<f) f=t;
}
printf("%lf",f);
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_24831/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_24831/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@f = dso_local local_unnamed_... |
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
int main (){
int x[10000],N,i,j,num;
scanf("%d",&N);
if(N<1 || N>10000){
printf("Please type 1 to 10000.");
exit(1);
}
num = N;
for(i=0;i<N;i++){
scanf("%d",&x[i]);
if(x[i]>100000000 || x[i] < 2){
printf("Please type 2 t... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_248360/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_248360/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 i,j,count=0,number,n;
scanf("%d",&n);
count=n;
for(i=0;i<n;i++){
scanf("%d",&number);
if(number>2&&number%2==0 ) count--;
else{
for(j=3;j<=sqrt(number);j+=2){
if... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_248403/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_248403/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 FuncBePrime(int n)
{
int i;
if(n < 2)
return 0;
else if(n == 2)
return 1;
if(n % 2 == 0)
return 0;
for(i = 3; i * i <= n; i += 2)
if(n % i == 0)
return 0;
return 1;
}
int main(void)
{
int n;
int buf;
int count = 0;
int i;
sc... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_248447/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_248447/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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>
#define N 10000
void prime(int);
int main()
{
int n,i;
int array[N];
int count=0,f,k=0,j;
scanf("%d", &n);
for ( i = 0; i < n; i++ ){
scanf("%d", &array[i]);
}
for(j=0;j<n;j++){
k=0;
for(i=2;i<=sqrt(array[j]);i++){
f=array[j]%i;
if(f... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_248490/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_248490/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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>
#define T 1
#define F -1
int Prime(int x)
{
if(x==2) return T;
if(x<2||x%2==0)return F;
int i=3;
while(i<=sqrt(x))
{
if(x%i==0)return F;
i += 2;
}
return T;
}
int main()
{
int cnt=0,n,x;
scanf("%d",&n);
for(int i=0;i<n;i++)
{
scanf("%d",&x);
if(... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_248555/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_248555/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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>
#define N_MAX 10000
int isPrime(int x)
{
int i;
if (x <= 3) {
return 1;
} else if (x % 2 == 0) {
return 0;
} else {
for (i = 3; i <= sqrt(x); i = i + 2) {
if (x % i == 0) {
return 0;
}
}
return 1;
}
}
int main(int argc, char *argv[... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_248599/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_248599/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int isPrime(int x){
int i;
if ( x == 2 ) return 1;
else if ( x < 2 || (x % 2 == 0)) return 0;
for ( i = 3; i*i <= x; i++){
if ( x % i == 0 ) return 0;
}
return 1;
}
int main(){
int x, t, status;
int d = 0;
while(1){
status = scanf("%d", &x);
if(status != 1) break;
t... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_248641/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_248641/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 PrimeJudge(int);
#define N 10000
int main(){
int i,n,flg,prime=0,num[N];
scanf("%d",&n);
for(i=0;i<n;i++){
scanf("%d",&num[i]);
flg=PrimeJudge(num[i]);
if(flg==0) prime++;
}
printf("%d\n",prime);
return 0;
}
int PrimeJudge(int data){
int i=3;
if(data=... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_248685/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_248685/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 P_num(int);
int main(){
int x,i,num,count=0;
scanf("%d",&x);
for(i=0;i<x;i++){
scanf("%d",&num);
if(P_num(num))count++;
}
printf("%d\n",count);
return 0;
}
int P_num(int x){
int i;
for(i=2;i<=sqrt(x);i++){
if(i==x)break;
if(x%i==0)return 0;
}
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_248728/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_248728/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 ans=0;
while(n) {
int x,i;
scanf("%d",&x);
for(i=2; i*i<=x; i++) {
if(x%i==0) break;
}
if(i*i>x) ans++;
n--;
}
printf("%d\n",ans);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_248771/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_248771/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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>
#define FALSE 0
#define TRUE 1
int isPrime(int x)
{
if (x <= 1) {
return FALSE;
}
int end = sqrt(x);
for(int i = 2; i <= end; i++) {
if (x % i == 0)
return FALSE;
}
return TRUE;
}
int main(void)
{
int n, x, count;
scanf("%d", &n);
count = 0;
for... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_248814/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_248814/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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;
int counter = 0;
scanf("%d\n",&n);
for(int i=0;i<n;i++){
int num;
scanf("%d\n",&num);
//sqrtはfloatを返す。1で割っても同じ
int end = sqrt(num)+1;
if(num==2 || num==3){
counter ++;
}else{
for(int j=2; j<end; j++){
if(num%j==0)... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_248865/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_248865/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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>
#define N 10000
int hantei (int);
int main(){
int a[N];
int i=0,j,l,num=0,count=0;
while(i<N){
if(scanf("%d",&a[i])==EOF)break;
i++;
num++;
}
for(j=0;j<num;j++){
l=hantei(a[j]);
if(l==1)count++;
}
printf("%d\n",count);
return 0;
}
int hantei (int... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_248922/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_248922/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 prime(int);
int main()
{
int num,in,t=0,i,j,judg;
scanf("%d",&num);
for(i = 0;i < num;i++)
{
scanf("%d",&in);
judg = prime(in);
if(judg == 1) t++;
}
printf("%d\n",t);
return 0;
}
int prime(int num)
{
int i;
if(num <= 3 && num > 1) return 1;
els... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_248973/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_248973/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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>
#define N 10000
int main(){
int num[N],n,i,j=3,count=0;
scanf("%d",&n);
for(i=0;i<n;i++)scanf("%d",&num[i]);
for(i=0;i<n;i++){
if(num[i]==2)count+=1;
else if(num[i]>2&&num[i]%2!=0){
while(j<=sqrt(num[i])){
if(num[i]%j==0){
count-=1;
break;
}
else j+=2... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249015/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249015/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 isPrime(int);
int count;
int main(void){
int i,j,m,a;
scanf("%d",&m);
for(i=0;i<m;i++){
scanf("%d",&a);
isPrime(a);
}
printf("%d\n",count);
return 0;
}
int isPrime(int d){
int i;
if(d==2){count++;return 0;}
if(d>2&&d%2==0)return 0;
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249059/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249059/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
int isPrime(int x){
int i;
if(x < 2) return 0;
else if(x == 2) return 1;
if(x % 2 == 0) return 0;
for(i = 3; i * i <= x; i += 2){
if(x % i == 0) return 0;
}
return 1;
}
int main(){
int n, x, i;
int cnt = 0;
scanf("%d", &n);
for(i = 0; i < n; i++){
scanf("%d", &x);
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249101/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249101/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
/*
cat <<EOF >mistaken-paste
*/
#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 VERYBIG 2000000000000007LL
#d... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249152/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249152/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@parent = dso_local local_u... |
#include<stdio.h>
int main(){
int n,a,b,i,k[20]={0};
char c[20];
scanf("%d %d %d",&a,&b,&n);
for(i=10;i>-1;i--){
c[i]=a%10-k[i]-b%10+'0';
if(c[i]<'0'){
c[i]+=10;
k[i-1]=1;
}
a/=10;
b/=10;
}
for(i=0;i<10;i++){
if(k[i]&&n&&c[i]-'9'){
c[i]++;
n--;
}
}//*/... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249196/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249196/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 maxn 100010
char s[maxn];
int n, ans[maxn], nxtL[maxn], preR[maxn];
int main()
{
scanf("%s", s);
n = strlen(s);
int i;
for (i = 1; i < n; ++i)
if (s[i] == 'R')
preR[i] = i;
else preR[i] = preR[i - 1];
for (i = n - 1; i >= 0; --i)
if (s[i] == 'L')
nxtL[i] = ... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249239/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249239/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 str[81];
int i,j,l;
while(fgets(str,sizeof(str),stdin) != NULL){
l = strlen(str);
for(i = 0; i < 26; i++){
if(strstr(str,"the") != '\0' || strstr(str,"this") != '\0' || strstr(str, "that") != '\0')
break;
else{
for(j =... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249332/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249332/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@stdin = external local_unn... |
#include <stdio.h>
#include <string.h>
#include <ctype.h>
int main(void){
int i,j,f;
char s[1030];
char t[3][5]={"the","this","that"};
while(fgets(s,1030,stdin)){
for(i=0;i<26;i++){
for(j=0;j<strlen(s);j++){
if(isalpha(s[j])){
if(s[j]=='z')s[j]='a';
else s[j]=(char)((int)s[j]+1);
}
}
f=0;
for(j=0;j<3;j++){
if(strstr(s,... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249390/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249390/source.c"
target datalayout = "e-m:e-p270: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.t = private u... |
#include<stdio.h>
#include<string.h>
char a[100];
int flag;
void shift(){
int i=0;
while(a[i]!='\0'){
if(a[i]>='a' && a[i]<='y')
a[i]++;
else if(a[i]=='z')
a[i]='a';
i++;
}
}
void match(int x){
char b1[5];
char b2[4];
char m1[2][5]={"that","this"};
char m2[4]={"the"};
int i... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249477/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249477/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@a = dso_local global [100 ... |
#include <stdio.h>
#include <string.h>
int main(void)
{
char str[80];
int i, len;
//int num1, num2, num3;
char *num1;
char *num2;
char *num3;
/*fgets(str, sizeof(str), stdin);
len = strlen(str);*/
//printf("%s\n", str);
while(fgets(str, sizeof(str), stdin) != 0){
l... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249527/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249527/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@stdin = external local_unn... |
#include <stdio.h>
#include <stdlib.h>
#define N 100
#define M 1000
#define INT(X) \
( *( (const int *)(X) ) )
int comparator (
const void * a,
const void * b
)
{
return ( INT( b ) - INT( a ) );
}
/** Application main entry point. */
int main (
int argc,
char * argv[ ]
)
{
int i;
for ( ; ... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249570/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249570/source.c"
target datalayout = "e-m:e-p270: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.tagD = type { i32, ... |
#include<stdio.h>
#include<string.h>
int main() {
long long int n,max=0,a[200000],b[200000],number;
scanf("%lld", &n);
for (int i = 1; i <= n; i++) {
scanf("%lld%lld", &a[i],&b[i]);
if (max < a[i]) { number = b[i];max=a[i]; }
}
printf("%lld", max+number);
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249613/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249613/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main()
{
unsigned int n;
int count = 0;
unsigned int bit = 1;
scanf("%d", &n);
for (; n / 2; n /=2) {
if (!(n % 2)) bit = 0;
count++;
}
printf("%d\n", count + bit);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249664/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249664/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#define N 1000000
int a[N+1];
int dp[N+1];
int min(int a, int b){
if(b>a)return a;
else return b;
}
int abs(int a){
if(a<0)return -1*a;
else return a;
}
int main(){
int i,j, n, k;
scanf("%d %d", &n, &k);
for(i=0;i<n;i++)scanf("%d", &a[i]);
for(i=0;i<n;i++)dp[i]=1e10;
dp[0]=0;... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249707/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249707/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <stdlib.h>
#define MAXN 100000
int A[MAXN+1];
int DP[MAXN+1];
int flog (int n, int k)
{
int i,tmp,j;
int min;
DP[1] = 0;
for ( i = 2; i <= k; i++ ) {
min = DP[1] + abs(A[1]-A[i]);
for ( j = 1; j < i; j++ ) {
tmp = DP[j] + abs(A[i]-A[j]);
if ( min > tmp ) min = tmp;
}
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249758/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249758/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@DP = dso_local local_unnam... |
#include <stdio.h>
#define MAX 111111
long abso(long x) {
return (x > 0) ? x : (-1 * x);
}
int min(int x, int y) {
return (x < y) ? x : y;
}
int max(int x, int y) {
return (x > y) ? x : y;
}
int main() {
int n, k;
scanf("%d %d", &n, &k);
int dp[MAX], nums[MAX];
dp[0] = 0;
for (i... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249800/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249800/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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() {
long *wp,w;
long N,i;
int K,*hp,k;
scanf("%ld %d",&N,&K);
wp=(long *)malloc((K+1)*sizeof(long));
hp=(int *)malloc((K+1)*sizeof(int));
scanf("%d",&hp[0]);
wp[0]=0;
for(i=1;i<=N-1;i++) {
k=K;
if(i<K) k=i;
f... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249844/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249844/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <math.h>
int main() {
double x1,y1,x2,y2;
scanf("%lf%lf%lf%lf",&x1,&y1,&x2,&y2);
printf("%.8lf\n",hypot(x1-x2,y1-y2));
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249895/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249895/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
#include<math.h>
int main( void )
{
double x1,y1;
double x2,y2;
double distance;
scanf( "%lf%lf%lf%lf", &x1, &y1, &x2, &y2 );
x1=(x1-x2);
x1 = (x1 < 0)? -1*(x1): x1;
y1=(y1-y2);
y1 = (y1 < 0)? -1*(y1): y1;
distance = sqrt( pow( x1, 2 )+pow( y1, 2 ) );
printf( "%.8lf\n... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249938/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249938/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <math.h>
int main(void){
double x1,y1,x2,y2;
scanf("%lf%lf%lf%lf",&x1,&y1,&x2,&y2);
printf("%.8lf\n",(sqrt((x2-x1)*(x2-x1)+(y2-y1)*(y2-y1))));
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_249989/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_249989/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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>
long long a[200000];
int cmp ( const void *a , const void *b ){
return *(long long *)a - *(long long *)b;
}
int main()
{
int i, j, n;
scanf("%d", &n);
for(i = 1; i <= n; i++)
scanf("%lld", &a[i]);
qsort(&a[1], n, sizeof(a[1]), cmp);
if(n % 2 != 0) printf("%d\n", n / 2);
els... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_25003/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_25003/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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(){
double x1,y1,x2,y2,xx,yy,result;
scanf("%lf %lf %lf %lf",&x1,&y1,&x2,&y2);
xx=pow(x1-x2, 2);
yy=pow(y1-y2, 2);
printf("%lf\n",sqrt(xx+yy));
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250073/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250073/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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> //math.h?????????????????????????????????????????????????????¨??????-lm???????????§???\\
??????????????????????????????
int main(void){
double x1,y1,x2,y2;
scanf("%lf %lf %lf %lf",&x1,&y1,&x2,&y2);
double l;
l = sqrt(pow(x2-x1,2) + pow(y2-y1,2));
printf("%lf\n",l);
retur... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250116/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250116/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
#include<math.h>
int main(){
double x1,y1,x2,y2;
double i,j,k;
scanf("%lf %lf %lf %lf", &x1, &y1, &x2, &y2);
i = pow((x2-x1),2.0);
j = pow((y2-y1),2.0);
k = sqrt(i+j);
printf("%f\n",k);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250167/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250167/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 n;
scanf("%d",&n);
int i,en[n],con=1;
int fre[n+1];
int va[n+1];
memset(fre, 0, sizeof fre);
for(i=0;i<n;i++){
scanf("%d",&en[i]);
en[i]=n-en[i];
fre[en[i]]++;
}
for(i=0;i<n;i++)if(fre[en[i]]%en[i])break;
if(i<n)printf("Impossible\n");
else{
p... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_25021/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_25021/source.c"
target datalayout = "e-m:e-p270:32:32-p271: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(void){
double x1,x2,y1,y2;
double ans;
scanf("%lf %lf %lf %lf",&x1,&y1,&x2,&y2);
ans = sqrt((x1-x2)*(x1-x2) + (y1-y2)*(y1-y2));
printf("%lf\n",ans);
return 0;
} | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250260/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250260/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 argc, char * argv[])
{
double x1,x2,y1,y2;
double dis=0;
scanf("%lf %lf %lf %lf",&x1,&y1,&x2,&y2);
dis = sqrt(pow(x2 - x1,2)+(pow(y2 - y1,2)));
printf("%f\n",dis);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250303/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250303/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include <math.h>
double dis(double x1, double y1, double x2, double y2)
{
return sqrt((x1 - x2) * (x1 - x2) + (y1 - y2) * (y1 - y2));
}
int main()
{
double x1, y1, x2, y2, d;
scanf("%lf %lf %lf %lf", &x1, &y1, &x2, &y2);
d = dis(x1, y1, x2, y2);
printf("%.6lf\n", d);
retur... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250347/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250347/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
#include<math.h>
int main(void) {
double a,b,c,d;
double e;
scanf("%lf%lf%lf%lf",&a,&b,&c,&d);
e=(a-c)*(a-c)+(b-d)*(b-d);
e=sqrt(e);
printf("%f",e);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250390/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250390/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
//ITP1-10-A: Distance
//2019.05.20
#include <stdio.h>
#include <math.h>
int main(void){
double x1, y1, x2, y2;
double distance;
scanf("%lf %lf %lf %lf\n", &x1, &y1, &x2, &y2);
distance = sqrt(pow(x2-x1, 2) + pow(y2-y1, 2));
printf("%lf\n", distance);
return 0;
}
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250433/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250433/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include<stdio.h>
#include<math.h>
int main(){
double a,b,c,d;
scanf("%lf %lf %lf %lf",&a,&b,&c,&d);
printf("%lf\n",sqrt(pow(c-a,2.0)+pow(d-b,2.0)));
return 0; }
| ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250477/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250477/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 l[10], v[2], all, i;
double t;
while(scanf("%d,%d,%d,%d,%d,%d,%d,%d,%d,%d,%d,%d", &l[0], &l[1], &l[2], &l[3], &l[4], &l[5], &l[6], &l[7], &l[8], &l[9], &v[0], &v[1]) != EOF){
all = 0;
for(i = 0; i < 10; i++){
all += l[i];
}
t = (double)all / (double)(v[0]+v[1]);
t... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250527/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250527/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
// AOJ Volume 0 Problem 0034
#include <stdio.h>
int main(void)
{
int l[10];
int sum_l;
float l1;
int l12;
int v1, v2;
int i;
while (scanf("%d,", &l[0]) != EOF){
for (i = 1; i < 10; i++){
scanf("%d,", &l[i]);
}
scanf("%d,%d", &v1, &v2);
sum_l = 0;
for (i = 0; i < 10; i++){
sum_l += l[i];
}
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250578/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250578/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
#include <stdio.h>
int main(void)
{
int a, b;
double pos;
int railWays[10];
int railLength;
int i;
while (~scanf("%d,", railWays)){
for (i = 1; i < 10; i++){
scanf("%d,", railWays + i);
}
scanf("%d,%d", &a, &b);
// input phase end
railLength = 0;
for (i = 0; i < 10; i++){
railLength += railW... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250620/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250620/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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 n;
scanf("%lld",&n);
long long ans[n+1];
for(long long i=1;i<=n;i++)ans[i]=0;
for(long long a=1;a<=100;a++){
for(long long b=a;b<=100;b++){
for(long long c=b;c<=100;c++){
if((a+b)*(a+b)+(c+b)*(c+b)+(a+c)*(a+c)<=2*n){
if(a==c){
... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250664/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250664/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-pc-linux-gnu"
@.str = private unnamed_add... |
//C - XYZ Triplets
//Hiia
#include <stdio.h>
#include <stdlib.h>//rannsuu, zettaichi(absolute)
#include <time.h>
//srand((unsigned int) time(0));
#include <math.h>//koudona keisann
#include <string.h>//hairetsu
#define max(p,q)((p)>(q)?(p):(q))
#define min(p,q)((p)<(q)?(p):(q))
typedef long long ll;
//#define N 9982443... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250721/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250721/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64: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, count = 0;
scanf("%d", &N);
for(int n=1;n<=N;n++){
count = 0;
for(int x=1;x<=(int)sqrt(n)+2;x++){
for(int y=x;y<=(int)sqrt(n)+2;y++){
for(int z=y;z<=(int)sqrt(n)+2;z++){
if(x*x+y*y+z*z+x*y+y*z+z*x==n){
if(x==y && y... | ; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/C/Source_250765/source.c'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/C/Source_250765/source.c"
target datalayout = "e-m:e-p270:32:32-p271:32: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.