Submission #1406658
Source Code Expand
//#define MyDebug #include <bits/stdc++.h> #define rep(i, first, to) for(int i = first; i < to; ++i) #define REP(i, first, to) for(int i = first; i <= to; ++i) #ifdef MyDebug #define debug(x) cerr << #x << " : " << x << endl #define debugP(x) cerr << x << endl #else #define debug(x) #define debugP(x) #endif using namespace std; typedef long long ll; char toBig(char c) { if ('a' <= c && c <= 'z') return (char)(c + 'A' - 'a'); return c; } char toSmall(char c) { if ('A' <= c && c <= 'Z') return (char)(c - 'A' + 'a'); debug(c); return (char)c; } string s; void solve() { cin >> s; cout << toBig(s[0]); rep(i, 1, s.size()) { cout << toSmall(s[i]); } cout << endl; } void test() { debug(toSmall('b')); } int main() { solve(); //test(); return 0; }
Submission Info
Submission Time | |
---|---|
Task | B - 名前の確認 |
User | daizu39 |
Language | C++14 (GCC 5.4.1) |
Score | 100 |
Code Size | 817 Byte |
Status | AC |
Exec Time | 1 ms |
Memory | 256 KB |
Judge Result
Set Name | All | ||
---|---|---|---|
Score / Max Score | 100 / 100 | ||
Status |
|
Set Name | Test Cases |
---|---|
All | sample_01.txt, sample_02.txt, test_AzielehadfJD.txt, test_Oq.txt, test_P.txt, test_Wi.txt, test_ZNEFzealEAkD.txt, test_aAZaz.txt, test_z.txt, test_zDkElDjNVmAq.txt |
Case Name | Status | Exec Time | Memory |
---|---|---|---|
sample_01.txt | AC | 1 ms | 256 KB |
sample_02.txt | AC | 1 ms | 256 KB |
test_AzielehadfJD.txt | AC | 1 ms | 256 KB |
test_Oq.txt | AC | 1 ms | 256 KB |
test_P.txt | AC | 1 ms | 256 KB |
test_Wi.txt | AC | 1 ms | 256 KB |
test_ZNEFzealEAkD.txt | AC | 1 ms | 256 KB |
test_aAZaz.txt | AC | 1 ms | 256 KB |
test_z.txt | AC | 1 ms | 256 KB |
test_zDkElDjNVmAq.txt | AC | 1 ms | 256 KB |