File tree Expand file tree Collapse file tree 18 files changed +107
-93
lines changed
Expand file tree Collapse file tree 18 files changed +107
-93
lines changed Original file line number Diff line number Diff line change 1616#include <cstdio>
1717int main() {
1818 int c;
19- while ((c = getchar()) != EOF) {
20- putchar(c);
19+ while ((c = std:: getchar()) != EOF) {
20+ std:: putchar(c);
2121 }
2222 if (c == EOF)
23- puts("REACHED END");
23+ std:: puts("REACHED END");
2424}
2525
2626```
2727* EOF[color ff0000]
28- * getchar[link /reference/cstdio/getchar.md]
29- * putchar[link /reference/cstdio/putchar.md]
30- * puts[link /reference/cstdio/puts.md]
28+ * std:: getchar[link /reference/cstdio/getchar.md]
29+ * std:: putchar[link /reference/cstdio/putchar.md]
30+ * std:: puts[link /reference/cstdio/puts.md]
3131
3232### 入力
3333```
Original file line number Diff line number Diff line change @@ -28,13 +28,13 @@ namespace std {
2828#include <cstdio>
2929
3030int main() {
31- FILE *fp = fopen("test.txt", "w");
32- fclose(fp);
31+ std:: FILE *fp = std:: fopen("test.txt", "w");
32+ std:: fclose(fp);
3333}
3434```
35- * fclose[ color ff0000]
36- * fopen[ link /reference/cstdio/fopen.md]
37- * FILE[ link /reference/cstdio/file.md]
35+ * std:: fclose[ color ff0000]
36+ * std:: fopen[ link /reference/cstdio/fopen.md]
37+ * std:: FILE[ link /reference/cstdio/file.md]
3838
3939## 処理系
4040- [ Clang] ( /implementation.md#clang ) : ??
Original file line number Diff line number Diff line change @@ -23,13 +23,13 @@ namespace std {
2323
2424int main() {
2525 int c;
26- while ((c = fgetc(stdin)) != EOF) {
27- putc(c, stdout);
26+ while ((c = std:: fgetc(stdin)) != EOF) {
27+ std:: putc(c, stdout);
2828 }
2929}
3030```
31- * fgetc[ color ff0000]
32- * putc[ link /reference/cstdio/putc.md]
31+ * std:: fgetc[ color ff0000]
32+ * std:: putc[ link /reference/cstdio/putc.md]
3333
3434### 入力
3535```
Original file line number Diff line number Diff line change @@ -25,12 +25,12 @@ namespace std {
2525
2626int main() {
2727 char str[10];
28- fgets(str, sizeof(str), stdin);
29- puts(str);
28+ std:: fgets(str, sizeof(str), stdin);
29+ std:: puts(str);
3030}
3131```
32- * fgets[ color ff0000]
33- * puts[ link /reference/cstdio/puts.md]
32+ * std:: fgets[ color ff0000]
33+ * std:: puts[ link /reference/cstdio/puts.md]
3434
3535### 入力
3636```
Original file line number Diff line number Diff line change 44* class[ meta id-type]
55
66``` cpp
7- typedef /* unspecified */ FILE;
7+ namespace std {
8+ typedef /* unspecified * / FILE;
9+ }
810```
911
1012## 概要
Original file line number Diff line number Diff line change @@ -24,19 +24,19 @@ namespace std {
2424#include <cstdio>
2525
2626int main() {
27- FILE *fp = fopen("test.txt", "w");
27+ std:: FILE *fp = std:: fopen("test.txt", "w");
2828 if (fp == NULL) {
29- printf("ファイルを開けませんでした\n");
29+ std:: printf("ファイルを開けませんでした\n");
3030 return 1;
3131 }
32- fclose(fp);
32+ std:: fclose(fp);
3333 return 0;
3434}
3535```
36- * fopen[ color ff0000]
37- * fclose[ link /reference/cstdio/fclose.md]
38- * FILE[ link /reference/cstdio/file.md]
39- * printf[ link /reference/cstdio/printf.md]
36+ * std:: fopen[ color ff0000]
37+ * std:: fclose[ link /reference/cstdio/fclose.md]
38+ * std:: FILE[ link /reference/cstdio/file.md]
39+ * std:: printf[ link /reference/cstdio/printf.md]
4040
4141## 処理系
4242- [ Clang] ( /implementation.md#clang ) : ??
Original file line number Diff line number Diff line change @@ -24,10 +24,10 @@ namespace std {
2424#include <cstdio>
2525
2626int main() {
27- fputc('a', stdout);
27+ std:: fputc('a', stdout);
2828}
2929```
30- * fputc[ color ff0000]
30+ * std:: fputc[ color ff0000]
3131* stdout[ link /reference/cstdio/stdout.md]
3232
3333### 出力
Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ namespace std {
2020#include <cstdio>
2121
2222int main() {
23- fputs("Hello, World!\n", stdout);
23+ std:: fputs("Hello, World!\n", stdout);
2424 return 0;
2525}
2626```
Original file line number Diff line number Diff line change 44* function[ meta id-type]
55
66``` cpp
7- int getc (FILE* stream);
7+ namespace std {
8+ int getc(FILE* stream);
9+ }
810```
911
1012## 概要
@@ -21,13 +23,13 @@ int getc(FILE* stream);
2123
2224int main() {
2325 int c;
24- while ((c = getc(stdin)) != EOF) {
25- putc(c, stdout);
26+ while ((c = std:: getc(stdin)) != EOF) {
27+ std:: putc(c, stdout);
2628 }
2729}
2830```
29- * getc[ color ff0000]
30- * putc[ link /reference/cstdio/putc.md]
31+ * std:: getc[ color ff0000]
32+ * std:: putc[ link /reference/cstdio/putc.md]
3133
3234### 入力
3335```
Original file line number Diff line number Diff line change 44* function[ meta id-type]
55
66``` cpp
7- int getchar ();
7+ namespace std {
8+ int getchar();
9+ }
810```
911
1012## 概要
@@ -22,13 +24,13 @@ int getchar();
2224#include <cstdio>
2325int main() {
2426 int c;
25- while ((c = getchar()) != EOF) {
26- putchar(c);
27+ while ((c = std:: getchar()) != EOF) {
28+ std:: putchar(c);
2729 }
2830}
2931```
30- * getchar[ color ff0000]
31- * putchar[ link /reference/cstdio/putchar.md]
32+ * std:: getchar[ color ff0000]
33+ * std:: putchar[ link /reference/cstdio/putchar.md]
3234* EOF[ link /reference/cstdio/eof.md]
3335
3436### 入力
You can’t perform that action at this time.
0 commit comments