#include <bits/stdc++.h>
int main() {
  char arr[100006];
  scanf("%s", arr);
  int l = strlen(arr);
  int count = 0;
  int d = 0;
  while (d < l) {
    if (arr[d] != 'a') count++;
    d++;
  }
  if (count % 2)
    printf(":(");
  else {
    int t, idx = l - count / 2;
    t = idx;
    d = 0;
    int flag = 0;
    while (idx != l && d < l) {
      if (arr[idx] == arr[d]) {
        idx++;
        d++;
      } else if (arr[d] != 'a') {
        flag = 1;
        break;
      } else
        d++;
    }
    if (idx != l) {
      printf(":(");
    } else {
      while (d < t) {
        if (arr[d] != 'a') flag = 1;
        d++;
      }
      if (flag)
        printf(":(");
      else {
        for (int i = 0; i < t; i++) printf("%c", arr[i]);
      }
    }
  }
  return 0;
}
