diff --git a/src/week1/BOJ1213/BOJ1213_V1.cpp b/src/week1/BOJ1213/BOJ1213_V1.cpp new file mode 100644 index 0000000..94f8d2c --- /dev/null +++ b/src/week1/BOJ1213/BOJ1213_V1.cpp @@ -0,0 +1,38 @@ +#include +using namespace std; +int cnt[26]; +string input; +int odd_num = -1; +int odd_count; +int main() { + + cin >> input; + + for (int i=0; i 1) { + cout << "I'm Sorry Hansoo"; + } else if (odd_count == 1) { + result += (char)(odd_num + 'A'); + } + + for (int i=25; i>=0; i--) { + for (int j=0; j<(cnt[i]/2); j++) { + result = result + (char)(i+'A'); + result = (char)(i+'A') + result; + } + } + + cout << result << "\n"; + return 0; +} \ No newline at end of file