#include <bits/stdc++.h>
using namespace std;
long long b[3][3];
int main() {
  string s;
  char ch;
  int x = 0, y = 0, a = 0;
  cin >> s;
  for (int i = 0; i < s.length(); i++) {
    a = s[i];
    if (a >= 97) {
      x++;
    } else {
      y++;
    }
  }
  for (int i = 0; i < s.length(); i++) {
    a = s[i];
    if (a < 97 && x >= y) {
      a = a + 32;
    } else if (a >= 97 && x < y) {
      a = a - 32;
    }
    ch = a;
    cout << ch;
  }
}
