#include <bits/stdc++.h>
using namespace std;
int alp[27];
int main() {
  int i, cna = 0, cno = 0, len, val = 0;
  vector<char> vec;
  vector<char> cpy;
  string second;
  cin >> second;
  len = second.size();
  for (i = 0; i < len; i++) {
    if (second[i] == 'a') {
      cna++;
    } else {
      cno++;
    }
  }
  if (cno % 2) {
    cout << ":(";
    return 0;
  }
  val = cno / 2;
  for (i = len - 1; i > len - 1 - val; i--) {
    if (second[i] == 'a') {
      cout << ":(";
      return 0;
    }
    vec.push_back(second[i]);
  }
  reverse(vec.begin(), vec.end());
  for (i = 0; i <= len - 1 - val; i++) {
    if (second[i] != 'a') {
      cpy.push_back(second[i]);
    }
  }
  if (cpy == vec) {
    for (i = 0; i <= len - 1 - val; i++) {
      printf("%c", second[i]);
    }
  } else {
    cout << ":(";
    return 0;
  }
}
