Go: package main

import (
	"bufio"
	"os"
	"fmt"
)

func reverse(s string) string {
	runes := []rune(s)
	for i, j := 0, len(runes)-1; i < j; i, j = i+1, j-1 {
		runes[i], runes[j] = runes[j], runes[i]
	}
	return string(runes)
}

func main() {
	scanner := bufio.NewScanner(os.Stdin)
	scanner.Scan()
	input := scanner.Text()
	fmt.Println(reverse(input))
}

C++: #include<iostream>
#include<string.h>
using namespace std;
 int c[33001],n,a,b,x[33001];
int lowbit(int n)
{
    return  (-n)&n;
}
int sum(int i)
{
    int s=0;
    while (i>0)
    {
        s+=c[i];
        i-=lowbit(i);
    }
    return s;
}
void  update (int pos ,int i )
{
    while (pos<=33000)
    {
        c[pos]+=i;
        pos+=lowbit(pos);

    }
}
int main()
{

   
    cin>>n;
    memset(c,0,sizeof(c));
    memset(x,0,sizeof(x));
for(int i=1;i<=n;i++)
    {
        scanf("%d%d",&a,&b);
        x[sum(a+1)]++;
        update(a+1,1);
}
    for(int i=0;i<n;i++)
    {
        printf("%d\n",x[i]);
    }
    return 0;
}

C++: #include <iostream>
#include <string>

using namespace std;

int main() {
    int i,len;
    string ch;

    cin >> ch;

    len = ch.length();

    for(i = 0;i < len / 2;i++){
        char box = ch[i];
        ch[i] = ch[len - i];
        ch[len - i] = box;
    }

    for(i = 0; i <= len;i++){
        cout << ch[i];
    }
    cout << endl;

    return 0;
}

C++: #include <iostream>
#include <string>
using namespace std;
int main() {
  string s;
  cin >> s;
  while(!s.empty()) {
	cout << s.back();
	s.pop_back();
  }
  cout << endl;
  return 0;
}

C++: #include <stdio.h>
#include <string.h>

int main()
{
char str[20];
 gets(str);
 strrev(str);
 printf("%s\n",str);
 return 0;
}

C++: #include <bits/stdc++.h>
using namespace std;
int main(){
	string s;
	reverse(s.begin(),s.end());
	cout << s << endl;
	return 0;
}

C++: #include <stdio.h>


int main(void){
    char st[20+1];
    char *pt;

    scanf("%s", st);
    for (pt=st; *pt!='\0'; pt++) ;
    for (pt--; pt!=st; pt--) printf("%c", *pt);
    printf("%c", *pt);
    return 0;
}

C++: #include<bits/stdc++.h>
using namespace std;

int main()
{
    string s;
    cin >> s;
    reverse_iterator<std::string::iterator> r = s.rbegin();
    string rev(r, s.rend());
    cout << rev << '\n';
}

C++: #include <bits/stdc++.h>
using namespace std;

int main() {
    string s;
    cin >> s;
    reverse(s.begin(),s.end());
    cout << s << endl;
    return 0;
}

C++: #include <stdio.h>
#include <iostream>
#include <string>

using namespace std;
int main() {
	string str;
	cin >> str;
	int n = str.length();
	string r_str;
	for(int i = 0; i < n; i++) {
		r_str += str.at(n - i - 1);
	}
	cout << r_str << endl;
	return 0;
}

C++: #include <iostream>
#include <string.h>
using namespace std;
int main()
{
   char str[21];
  while(cin>>str)
{
   int len=strlen(str);
   for(int i=len-1;i>=0;i--)
   cout<<str[i];
   cout<<endl;
  }
  return 0;
}

C++: #include<iostream>
#include<string>
using namespace std;
int main(){
	string s;
	cin >> s;
	if(s.size()<=20){
		for(int i=s.size()-1;i>=0;i--){
			cout << s[i];
		}
		cout << endl;
	}
	return 0;
}

C++: #include <iostream>
#include <string>

using namespace std;

int main() {
    int i,len;
    string ch;

    //while(cin >> ch){

    len = ch.length();

    for(i = 0;i < len / 2;i++){
        char box = ch[i];
        ch[i] = ch[len - i];
        ch[len - i] = box;
    }

    for(i = 0; i <= len;i++){
        cout << ch[i];
    }
    cout << endl;

    // }

    return 0;
}

C++: //Reverse Sequence
#include<bits/stdc++.h>
using namespace std;

int main(){
  char str[21];
  scanf("%s", str);
  for(int i=0; i<strlen(str); i++){
    printf("%c", str[strlen(str)-i-1]);
  }
  puts("");
  return 0;
}

C++: #include<iostream>
#include<string>

using namespace std;

int main(){
  string str;
  cin >> str;

  int a = str.size();
  char swap;
  for(int i = 0; i < a/2; i++){
    swap = str[i];
    str[i] = str[a-i-1];
    str[a-i-1] = swap;
  }

  cout << str << endl;
}

C++: #include <iostream>
#include<string>
using namespace std;


int main(){
	string s;
	cin>>s;
	for(int i=s.size()-1;i--){
		cout<<s[i];
	}cout<<endl;
}

C++: #include <iostream>
using namespace std;

int main() {
  int n;
  char s[21];
  cin >> s;
  for (n=0;s[n]!=0;n++);
  for (int i=0;i<n;i++) {
    cout << s[n-i-1];
  }
  cout << endl;
  return 0;
}

C++: #include <iostream>
#include <string.h>
#include <algorithm>
#define ll long long
using namespace std;

int main()
{
    ios_base::sync_with_stdio(false);
    cin.tie(0);
    cout.tie(0);
    
    string s1;
    while(cin >> s1)
    {
        for(int i=s1.length()-1;i>=0;i--) cout << s1[i];
        cout << "\n";
    }
    return 0 ;
}

C++: #include <bits/stdc++.h>
using namespace std;
#define rep(i,n) for (int i = 0; i < (n); i++)
#define repd(i,a,b) for (int i = (a); i < (b); i++)
typedef long long ll;
int main(void)
{
	string str;
	cin >> str;
	reverse(str.begin(), str.end());
	cout << str << endl;
}

C++: #include<iostream>
#include<string>
using namespace std;
int main() {
	string a;
	getline(cin, a);
	int len = a.length();
		for (int i = len-1; i >=0; i--) {
		cout << a[i];
	}
	cout << endl;
	return 0;
}

C++: #include <iostream>
#include <string>

using namespace std;

int main (){
	string str;
	cin >> str;
	for(int i = str.size()-1; i >= 0; i--) cout << str[i];
	cout << endl;
	return 0;
}

C++: #include<iostream>
#include<string>

using namespace std;

int main()
{
	string str;
	
	cin >> str;
	
	for(int i = str.length(); i > -1; i--){
		cout << str[i-1];
	}
	cout << endl;
}

C++: #include<iostream>
#include<cstring>
using namespace std;
	
int main()
{
	char str[19];
	cin>>str[19];
	int j=strlen(str);
	j-=1;
	for(int i=j;i>=0;i--){
	cout<<str[i];
	}
	return 0;
}

C++: #include <bits/stdc++.h>

using namespace std;

typedef vector<int> vi;
typedef vector<vi> vii;
typedef vector<string> vs;
typedef vector<bool> vb;
typedef vector<vb> vbb;
typedef pair<int, int> pii;
typedef long long ll;
typedef unsigned long long ull;

#define all(a)  (a).begin(),(a).end()
#define rall(a) (a).rbegin(), (a).rend()
#define pb push_back
#define mp make_pair

#define loop(i,a,b) for(int i=(a);i<ull(b);++i)
#define rep(i,n) loop(i,0,n)

const double eps = 1e-10;
const double pi  = acos(-1.0);
const double inf = (int)1e8;

int main(){
    string a;
    cin >> a;
    reverse(a.begin(), a.end());
    cout << a << endl;
}

C++: #include <iostream>

int main() {
	char str[21];
	std::cin >> str;

	for (int i = strlen(str) - 1; i >= 0; i--)
			std::cout << str[i];
}

C++: #include <bits/stdc++.h>
using namespace std;

int main(){
  string s;cin>>s;
  reverse(s.begin(),s.end());
  cout<<s<<endl;
  return EXIT_SUCCESS;
}

C++: #include <cstdio>
#include <cstring>
using namespace std;

int main(){

char str[21];
scanf("%s",str);

for(int i=strlen(str);i>=0;i--)
	printf("%c",str[i]);
printf("\n");

return 0;		
}

C++: #include <iostream>
#include <string>
using namespace std;

int main(){
  string s;
  cin>>s;
  for(string::reverse_iterator r = s.rbegin();r!=s.rend();r++) cout<<*r;
  cout<<endl;
  return 0;
}

C++: #include <iostream>
#include <string>
#include <vector>
#include <algorithm>
#include <set>
#include <map>
//ranker
using namespace std;

using ll = long long;
using ull = unsigned long long;
using vi = vector<int>;
using vvi = vector<vi>;
using vvvi = vector<vvi>;
using pii = pair<int, int>;
using pis = pair<int, string>;
using psi = pair<string, int>;
using D = double;


int main()
{
    string str;

    cin >> str;
    reverse( str.begin() , str.end() );
    cout << str << endl;

    return 0;
}

C++: #include <cstdio>
#include <algorithm>
using namespace std;

int main(int argc, char *argv[]) {
	char rcv[20];
	char out[20];
	fscanf(stdin, "%s", rcv);
	int cnt = 0;
	for (int i = 0; i < 20; i++) {
		if (rcv[i] == '\0') {
			for (int j = i-1; j !=-1; j--) {
				out[cnt] = rcv[j];
				cnt++;
			}
			out[cnt] = '\0';
			break;
		}
	}
	printf("%s", out);
	
	return 0;
}