include iostream include math using namespace std int main string str

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
#include <iostream>
#include <math.h>
using namespace std;
int main() {
string str, result;
getline(cin, str);
int half = ceil(str.length() / 2);
result = str.substr(half, str.length()) + str.substr(0, half);
cout << result;
}