#include using namespace std; int main() { int N, K; string S; cin >> N >> K >> S; cout << S.substr(K - 1) << S.substr(0, K - 1) << "\n"; }