選択できるのは25トピックまでです。 トピックは、先頭が英数字で、英数字とダッシュ('-')を使用した35文字以内のものにしてください。
 
 
 

20 行
428 B

  1. #include <stdio.h>
  2. #include <string.h>
  3. int main() {
  4. char s[257], c;
  5. int i = 0;
  6. while ((c = getc(stdin)) != '.') {
  7. if (c == '\n')
  8. break;
  9. s[i++] = c;
  10. }
  11. s[i] = '\0';
  12. // i is already the size of s. I've used strlen to follow the 'hints'
  13. // section.
  14. putc('\"', stdout);
  15. for (i = strlen(s) - 1; i >= 0; --i) {
  16. putc(s[i], stdout);
  17. }
  18. putc('\"', stdout);
  19. }