#include <bits/stdc++.h>
using namespace std;
int main() {
  char in[1000001], out[1000001];
  cin >> in;
  int limit = strlen(in), half = 0, y, x = 0, ic, z = 0, c = 0;
  for (int i = 0; i < limit; i++) {
    if (in[i] == in[limit - i - 1]) {
      c++;
      if (c == limit) {
        cout << in << endl;
        return 0;
      }
    }
  }
  half = limit / 2;
  for (y = 0; y < limit; y++) {
    if (in[y] != 0) out[y] = in[y];
  }
  x = y;
  while (in[z] != 0) {
    out[x] = in[limit - z - 1];
    ic = x;
    x++;
    z++;
  }
  out[ic + 1] = 0;
  cout << out << endl;
  return 0;
}
