Atcode ABC - A - Rotate

 #include<bits/stdc++.h>

using namespace std;


#define sf scanf

#define pf printf


const int high=1e3+5;


int main()

{

    string s, ans="";


    while(cin >> s)

    {

        int len = s.length();


        for(int i=1; i<len; i++)

        {

            ans += s[i];

        }


        ans+=s[0];


        cout << ans << "\n";


        ans.clear();

    }


    return 0;

}

Comments

Popular posts from this blog

SPOJ-CMG - Collecting Mango

LightOJ 1009 - Back to Underworld

LeetCode Palindrome Number