#include <bits/stdc++.h>
using namespace std;
int main() {
  int cnt{0}, cnT{0};
  string s;
  cin >> s;
  for (int i = 0; i < s.length(); ++i) {
    if (s[i] > 90) {
      cnt++;
    } else
      cnT++;
  }
  for (int j = 0; j < s.length(); j++) {
    if (cnt >= cnT && s[j] < 91) {
      s[j] = s[j] + 32;
    } else if (cnt < cnT && s[j] > 91) {
      s[j] = s[j] - 32;
    }
    cout << s[j];
  }
}
