Problem: Vasya is very upset that many people on the Net mix uppercase and lowercase letters in one word. That's why he decided to invent an extension for his favorite browser that would change the letters' register in every word so that it either only consisted of lowercase letters or, vice versa, only of uppercase ones. At that as little as possible letters should be changed in the word. For example, the word HoUse must be replaced with house, and the word ViP — with VIP. If a word contains an equal number of uppercase and lowercase letters, you should replace all the letters with lowercase ones. For example, maTRIx should be replaced by matrix. Your task is to use the given method on one given word.

Input

The first line contains a word s — it consists of uppercase and lowercase Latin letters and possesses the length from 1 to 100.

Output

Print the corrected word s. If the given word s has strictly more uppercase letters, make the word written in the uppercase register, otherwise - in the lowercase one.

Examples

Input

HoUse


Output

house


Input

ViP


Output

VIP


Input

maTRIx


Output

matrix

Solution (in PYTHON3):

Solution:
### hackerrank ###


### ******** Question https://www.hackerrank.com/challenges/reduced-string/problem
### Given a string, repeatedly remove adjacent pairs of matching characters and then print the reduced result.

# def super_reduced_string(s):
#     res = []
#     for c in s:
#         #print(c)
#         print(res)
#         if res and res[-1] == c:
#             res.pop()
#             print(res)
#         else:
#             res.append(c)
#     res = ''.join(res)
#     return res or "Empty String"

# print(super_reduced_string(input()))


# def camelcase(n):
#     count = 0
#     for i in n:
#         if i in 'ABCDEFGHIJKLMNOPQRSTUVWXYZ':
#             count = count + 1

#     return count + 1

# print(camelcase(input()))



### ******** Question - https://www.hackerrank.com/challenges/sherlock-and-valid-string


# def isValid(s):
#     #Create a list containing just counts of each distinct element
#     freq = [s.count(letter) for letter in set(s) ]
#     print(freq)

#     #If all values the same, then return 'YES'
#     if max(freq)-min(freq) == 0:
#         return 'YES'
#     #If difference between highest count and lowest count is 1
#     #and there is only one letter with highest count, 
#     #then return 'YES' (because we can subtract one of these 
#     #letters and max=min , i.e. all counts are the same)
#     elif freq.count(max(freq)) == 1 and max(freq) - min(freq) == 1:
#         return 'YES'
#     #If the minimum count is 1
#     #then remove this letter, and check whether all the other
#     #counts are the same
#     elif freq.count(min(freq)) == 1:
#         freq.remove(min(freq))
#         if max(freq)-min(freq) == 0:
#             return 'YES'
#         else:
#             return 'NO'
#     else:
#         return 'NO'

# print(isValid(input()))


### my implementation

# def sherlock(n):
#     freq = [n.count(i) for i in set(n)]

#     if max(freq)-min(freq)==0: #condition 1
#         return "YES"
#     elif freq.count(max(freq))==1 and max(freq)-min(freq)==1: #condition 2
#         return "YES"
#     elif freq.count(min(freq))==1:  # condition 3
#         freq.remove(min(freq))
#         if max(freq)-min(freq)==0:  # condition 4 sub-condition of 3
#             return "YES"
#         else:
#             return "NO"
#     else:
#         return "NO"

#print(sherlock(input()))





### Question - 
n=input()
count_lower = 0
count_upper = 0

for i in n:
    if i in 'ABCDEFGHIJKLMNOPQRSTUVWXYZ':
        count_upper +=1
    else:
        count_lower += 1

if count_lower > count_upper:
    print(n.lower())
elif count_lower <count_upper:
    print(n.upper())
elif count_upper==count_lower:
    print(n.lower())