結果
問題 | No.400 鏡 |
ユーザー |
![]() |
提出日時 | 2016-07-22 22:32:44 |
言語 | C++11 (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 1 ms / 2,000 ms |
コード長 | 210 bytes |
コンパイル時間 | 115 ms |
コンパイル使用メモリ | 21,888 KB |
実行使用メモリ | 6,820 KB |
最終ジャッジ日時 | 2024-11-06 09:04:47 |
合計ジャッジ時間 | 761 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 4 |
other | AC * 8 |
コンパイルメッセージ
main.cpp: In function ‘int main()’: main.cpp:6:14: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 6 | scanf("%s", str); | ~~~~~^~~~~~~~~~~
ソースコード
#include <stdio.h>char str[42];int main() {scanf("%s", str);int i;for(i = 0; str[i] != '\0'; i++) {str[41 - i] = (str[i] == '<' ? '>' : '<');}printf("%s\n", &str[41 - i + 1]);return 0;}