結果
問題 | No.163 cAPSlOCK |
ユーザー |
![]() |
提出日時 | 2015-04-25 14:23:59 |
言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 2 ms / 5,000 ms |
コード長 | 332 bytes |
コンパイル時間 | 409 ms |
コンパイル使用メモリ | 55,704 KB |
実行使用メモリ | 6,944 KB |
最終ジャッジ日時 | 2024-07-05 02:20:15 |
合計ジャッジ時間 | 1,146 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 20 |
ソースコード
#include <iostream> #include <cstdio> #include <string> using namespace std; #define a 'a' #define z 'z' #define A 'A' #define Z 'Z' int main(){ string s; cin>>s; for(int i=0;i<(int)s.size();i++){ if(A<=s[i]&&s[i]<=Z) printf("%c",(char)s[i]-A+a); else if(a<=s[i]&&s[i]<=z) printf("%c",s[i]-a+A); } cout<<endl; return 0; }