#include <bits/stdc++.h>
using namespace std;
#pragma warning(disable : 4996)
const double PI = acos(-1);
const long long N = 500005, md = 1e9 + 7, inf = 1e18, iinf = 1e9 + 5, MX = 3e5;
long long g, w, h, x, y, z, i, j, k, q, n, cnt, res, sum, r[N], a[N], b[N];
char c[N];
string s, t;
pair<int, int> p[N];
vector<int> e[N];
int main() {
  ios::sync_with_stdio(false), cin.tie(0);
  cin >> s;
  y = s.size();
  vector<char> e, f;
  for (long long i = 0; i < y; i++)
    if (s[i] == 'a') x++;
  if ((y - x) % 2 == 0) {
    z = (y - x) / 2;
    for (long long i = 0; i < y - z; i++)
      if (s[i] ^ 'a') e.emplace_back(s[i]);
    for (long long i = y - z; i < y; i++) f.emplace_back(s[i]);
    if (e == f) {
      for (long long i = 0; i < y - z; i++) cout << s[i];
      exit(0);
    }
  }
  cout << ":(";
}
