Go: package main

import "fmt"

func main() {
	var str string
	var result string

	fmt.Scanf("%s", &str)

	for i := len(str) - 1; i >= 0; i-- {
		result += string(str[i])
	}

	fmt.Println(result)
}

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

using namespace std;

/*-------------------------------*/
#define FOR(i, a, b) for(int i = (a); i < (b); i++)  //a~(b - 1)?????§
#define all(i) (i).begin(),(i).end() //??¨??????(sort??¨???)
#define mp make_pair //mp(OO, OO)??¨???:::pint??¨???

typedef long long ll;
typedef pair<int, int> pint;
typedef vector<int> vi;
typedef vector<vector<int> > vii;
typedef vector<long long> llv;
typedef vector<pint> vpint;
/*-------------------------------*/

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

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

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

C++: #include<stdio.h>
#include<string.h>
int main(){
int i;
char s[50];
scnaf("%s",s);
for(i=strlen(s)-1;i>-1;i--)printf("%c",s[i]);
printf("\n");
return 0;}

C++: #include <iostream>
using namespace std;
int main()
{
    string s;
    while(getline(cin, s))
    {
        string res;
        istringstream ss(s);
        string c;
        while(ss >> c)
        {
            for(int i = c.length() - 1; i >= 0; i--)
                res += c[i];
            res += " ";
        }
        res.erase(res.length() - 1, 1);
        cout << res << endl;
    }
    return 0;
}

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

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

  auto itr = input.end();
  while(itr != input.begin()) {cout << *(--itr);}
  cout << endl;
  return 0;
}

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

int main(void){
  std::string str;
  int i,n,v;
  std::cin >> str;
  i =str.size();
  v =i+1;
  for(n=0;n<v;n++){
    std::cout << str[i];
    i--;
  }
  std::cout << std::endl;
  return 0;
}

C++: #include <iostream>
#include <cstring>
#include <cstdio>

using namespace std;

void sort(char *str){
	int len, len2 = 0;
	char work; 
	len = strlen(str);

	for(len = len - 1; len > len2; len--, len2++){
		work = str[len];
		str[len] = str[len2];
		str[len2] = work;
	}
}

int main(){
	char str[20];
	cin >> str;
	sort(str);
	cout << str << endl;
	return 0;
}

C++: 
using namespace std;

main(){
  
  char str[21];
  int i=0;
  while(cin >> str[i]){i++;}
  
  i--;
  int j=i;
  for(j=i;j>=0;j--){
    
    cout << str[j] ; 
  }
  cout << endl;
  return 0;
}

C++: #include<iostream>
using namespace std;
void print();
int main()
{
	print();
	cout.put('\n');
}

void print()
{
	char c = cin.get();
	if (c == '\n');
	else
	{
		print();
		cout << c;
	}
}

C++:  /*
Write a program which reverses a given string str.
 */

#include <iostream>
#include <algorithm>
#include <string>

using namespace std;

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

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

using namespace std;

string reverse(string s);

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

    cout << reverse(str) << endl;
}

string reverse(string s)
{
    string rev;
    int len = s.length();

    for(int i = 1; i <= len; i++)
        rev += s.substr(len - i, 1);

    return rev;
}

C++: #include<iostream>

using namespace std;

main(){
  
  char str[21];
  int i=0;
  while(cin >> str[i]){i++;}
  
  i--;
  int j=i;
  for(j=i;j>=0;j--){
    
    cout << str[j] ; 
  }
  cout << '\0' ;

  cout << endl;
  return 0;
}

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

int main(int argc, char** argv) {
	char str[20];
	int len, i;

	std::cin >> str;
	len = strlen(str);
	
	for(i = len - 1; i >= 0; i--) {
		std::cout << str[i];
	}
	std::cout << std::endl;
}

C++: #include<cstdio>
#include<iostream>
using namespace std;
int main()
{
	char str[21];
	char str2[21];
	int i, cont = 0;
	
	scanf("%s",str);
	
	for(i = 0; str[i] != '\0'; i++){
	}
	for(;i > -1; i--){
		str2[cont] = str[i-1];
		cont++;
	}
	cout << str2 << endl;
	return 0;
}

C++: #include<bits/stdc++.h>
using namespace std;
#define mp make_pair
#define fi first
#define se second
#define ll long long
#define pb push_back

# define inOut(a,b) freopen(a,"r",stdin);freopen(b,"w",stdout);
# define RESET(a) memset(a,0,sizeof(a))
# define MEMO(a) memset(a,-1,sizeof(a))
# define DEBUG puts("Debug-Has-Come-Until-Here")


typedef pair<int,int> ii;
typedef vector<int> vi;
typedef vector<ii> vii;

int main(){
	cin.tie(NULL);
	
	char str[24];
	int i;
	scanf("%s",str);
	for (i=strlen(str)-1; i>=0; i--){
		printf("%c",str[i]);
	}
	printf("\n");

	return 0;
}

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

int main(){

  string str;

  cin>>str;
  reverse(str.begin(), str.end());

  cout<<str<<endl;
  
  return 0;
}

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

C++: #include<iostream>
#include<cstring>
using namespace std;
int main(){
	char stra[21],strb[21];
	int a,c;
	cin>>stra;
	a = strlen(stra);
	for(int i=0;i<a;i++){
		c = a - i -1;
		strb[i]=stra[c];
	strb[i+1]='\0';
	}
	cout<<strb<<endl;	
}

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

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

int main() {
	std::string str;

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

	return 0;
}

C++: #include<bits/stdc++.h>
using namespace std;
int main()
{
    int a,b,i,j;
    char ar[120];
    while(gets(ar))
    {
        a=strlen(ar);
        for(i=a-1;i>=0;i--)
        {
            printf("%c",ar[i]);
        }
        printf("\n");
    }
    return 0;
}

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

int main(void) {
    char str[20];
    int size;
    
    cin >> str;
    size = strlen(str);
    for(int i = 1; i <= size; ++i) {
        cout << str[size - i];
    }
    cout << endl;
}

C++: //"push hoge"と言われたらhogeを最後に入れ、"pop"と言われたら最後尾を取りだす。"quit"で終わり。
#include<iostream>
using namespace std;

int main(){
	char str[20];
	int hoge = 0;

	cin >> str;
	for(int i=0;i<20;i++){
		if(str[i] == '\0'){
			hoge = i;
			break;
		}
		hoge = i-1;
	}
	for(int i=hoge;i>=0;i--)
		cout << str[i];
	cout << endl;

	return 0;
}

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

int main()
{
    string A;
	char R;

	cin >> A;	
	for(int i=0; i<A.length()/2; i++){
		R = A[i];
		A[i] = A[A.length()-i-1];
		A[A.length()-i-1] = R;
	}
	cout << A << "\n";
	
    return 0;
}

C++: #include <iostream>
#include <algorithm>
#include <vector>
#include <functional>
#include <sstream>
#include <stdio.h>
using namespace std;

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

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

C++: #include <cstdio>
#include <cstring>
#include <algorithm>

using namespace std;

int main()
{
	char k[100];
	scanf("%s",k);
	reverse(k,k+strlen(k));
	printf("%s",k);
	return 0;
}

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

C++: #include<stdio.h>
int main(){
int i;
char str[21];
for(i=0;;i++){
str[i]=getchar();
if(str[i]=='\n')
	break;
}
for(;i>0;i--){
printf("%c",str[i-1]);
}
return 0;
}