This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <stdio.h> | |
| int main (){ | |
| char s[9999]; | |
| while(gets(s)) | |
| printf("hello, %s\n",s); | |
| return 0; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| #include <string> | |
| using namespace std; | |
| int main (){ | |
| string input; | |
| while(cin >> input) | |
| cout << "hello, " << input << endl; | |
| return 0; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <stdio.h> | |
| int main(){ | |
| int a, b; | |
| while(scanf("%d%d",&a,&b)!= EOF) | |
| printf("%d\n",a+b); | |
| return 0; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <stdio.h> | |
| int main(){ | |
| int M,D,S; | |
| while(scanf("%d%d",&M,&D)!= EOF){ | |
| S = (M*2 + D) % 3; | |
| if(S == 0) | |
| printf("普通\n"); | |
| else if (S == 1) | |
| printf("吉\n"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <stdio.h> | |
| int main(){ | |
| int year; | |
| while(scanf("%d",&year)!= EOF){ | |
| if((year % 4 == 0) && (year % 100 != 0)) | |
| printf("閏年\n"); | |
| else if(year % 400 == 0) | |
| printf("閏年\n"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <stdio.h> | |
| int main (){ | |
| int a,b,c,d,e,n,i; | |
| while(scanf("%d",&n)!= EOF){ | |
| for ( i = 0 ; i < n ; i ++){ | |
| scanf("%d%d%d%d",&a,&b,&c,&d); | |
| if (c - b == b - a) | |
| printf("%d %d %d %d %d\n",a,b,c,d,d*2 - c); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <stdio.h> | |
| #include <math.h> | |
| int main (){ | |
| int a,b,c; | |
| int x = 0, y = 0; | |
| while(scanf("%d%d%d",&a,&b,&c)!= EOF){ | |
| if (b*b-(4*a*c) > 0){ | |
| x = ((-b) + sqrt(b*b-(4*a*c)))/(2*a); | |
| y = ((-b) - sqrt(b*b-(4*a*c)))/(2*a); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <stdio.h> | |
| #include <string.h> | |
| //input - 7 = output | |
| int main (){ | |
| char str[100000]; | |
| while(gets(str)!=NULL){ | |
| int i, leng; | |
| leng = strlen(str); | |
| for( i = 0 ; i < leng ; i ++) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <stdio.h> | |
| int main (){ | |
| int in; | |
| while(scanf("%d",&in)!=EOF){ | |
| int i; | |
| int count = 0; | |
| for ( i = 2 ; i * i <=in ; i ++){ | |
| while(in % i == 0){ | |
| count++; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <stdio.h> | |
| int main (){ | |
| int row; | |
| int column; | |
| int array[100][100]; | |
| while(scanf("%d%d",&row,&column)!=EOF){ | |
| int x,k,y,t; | |
| for(x = 0 ; x < row ; x++){ |
OlderNewer