diff --git a/1-10.c b/1-10.c new file mode 100644 index 0000000..43cc196 --- /dev/null +++ b/1-10.c @@ -0,0 +1,23 @@ +#include +int main() { + int c; + while ((c=getchar()) != EOF){ + if (c == '\t'){ + putchar('\\'); + putchar('t'); + continue; + } + if (c == '\b'){ + putchar('\\'); + putchar('b'); + continue; + } + if (c == '\\'){ + putchar('\\'); + putchar('\\'); + continue; + } + putchar(c); + } + return 0; +}