#include <bits/stdc++.h>
using namespace std;
using namespace std;
int main(int argc, char const *argv[]) {
  string s, l, f;
  cin >> s;
  for (int i = 0; i < s.length(); ++i) {
    if (s[i] != 'a') {
      l += s[i];
    }
  }
  for (int i = 0; i < l.length() / 2; ++i) {
    f += l[i];
  }
  if (l.length() % 2 != 0) {
    cout << ":(";
    return 0;
  }
  int j = 1;
  for (int i = f.length() - 1; i >= 0; i--) {
    if (s[s.length() - j] == f[i])
      j++;
    else {
      cout << ":(";
      return 0;
    }
  }
  for (int i = 0; i <= (s.length() - f.length() - 1); ++i) cout << s[i];
}
