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:
"""
 __  __ _                   
|  \/  (_)_ __ ___  _ __    
| |\/| | | '__/ _ \| '_ \  
| |  | | | | | (_) | | | | 
|_|  |_|_|_|  \___/|_| |_|  
"""
"""

░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░████████░░░░░░░░░░░░░░░░░░░░
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░█████████░░░░░░░░░░░░░░░░░▌░░░
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░◐◐◐█████████▀▀▀▀▀▀🔥░░░░░░░░███
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░█████████░░░░░░░░░░░░░░░░░░░░▌░░░
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░█████████░░░░░░░░░░░░░░░░░░░░█▌░░░
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░▄▄▀█████████████████████████████████████████████████
░░░░░░░░░░░░░░░░░░░░░░░░░░▄▄▄████▄████████ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ████
░░░░░░░░░░░░░░░░░░░░░░░░░░░▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀█████████▀▀▀▀▀▀▀▀▀
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░█████████░░░░░░░░░░░░░░░░░░░░░░
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░◐◐◐█████████▀▀▀▀▀▀🔥░░░░░░░░░░
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░█████████░░░░░░░░░░░░░░░░░░░░
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░█████████░░░░░░░░░░░░░░░░░░░
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░████████░░░░░░░░░░░░░░░░░░
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░███████░░░░░░░░░░░░░░░░░
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░██████░░░░░░░░░░░░░░░░
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░█████░░░░░░░░░░░░░░░
"""
"""
                          / \  //\
            |\___/|      /   \//  \\
            /0  0  \__  /    //  | \ \    
           /     /  \/_/    //   |  \  \  
           @_^_@'/   \/_   //    |   \   \ 
           //_^_/     \/_ //     |    \    \
        ( //) |        \///      |     \     \
      ( / /) _|_ /   )  //       |      \     _\
    ( // /) '/,_ _ _/  ( ; -.    |    _ _\.-~        .-~~~^-.
  (( / / )) ,-{        _      `-.|.-~-.           .~         `.
 (( // / ))  '/\      /                 ~-. _ .-~      .-~^-.  \
 (( /// ))      `.   {            }                   /      \  \
  (( / ))     .----~-.\        \-'                 .~         \  `. \^-.
             ///.----..>        \             _ -~             `.  ^-`  ^-_
               ///-._ _ _ _ _ _ _}^ - - - - ~                     ~-- ,.-~
                                                                  /.-~

"""
"""
  ____          _      _____                       
 / ___|___   __| | ___|  ___|__  _ __ ___ ___  ___ 
| |   / _ \ / _` |/ _ \ |_ / _ \| '__/ __/ _ \/ __|
| |__| (_) | (_| |  __/  _| (_) | | | (_|  __/\__ \
 \____\___/ \__,_|\___|_|  \___/|_|  \___\___||___/
"""
"""
n = int(input())
os=0
ch=[]
for i in range(n):
	m = int(input())
	ch.append(m)	
	if ch[0]==10:		
		if 1 in ch:
			print((len( ch[:ch.index(1)])))
			break
	else:
		if 10 in ch:
			print((len( ch[:ch.index(10)])))
			break
"""
"""
n,m = map(int,input().split())
m = float(m)
mi = []
for i in range(n):
	a,b = map(float,input().split())
	mi.append((a*m)/b)
print(round(min(mi),6))
"""
"""
l = input().split()
l = set(l)
print(len(l))

"""
"""	
x = input()
y = x[1:-1]
z = set(y.split(', '))
if x == "{}":
	print(0)
else:
	print(len(z))
"""
"""
n,k = map(int,input().split())
L = sorted(map(int, input().split()))
res = [L[0]]
for i in range(1,n):
    if L[i] != L[i-1]:
        res.append(L[i]-L[i-1])
l = len(res)
if k > l:
    res += [0]*(k-l)
for i in range(k):
    print(res[i])

"""	
"""
from math import*
s,k = map(int,input().split(" "))
sq = input().split()
score = 0
pol = ""
for i in range(len(sq)):
	if sq[i]>=sq[i-1]:
		score+=1
print(ceil(score/len(sq))+ceil(score/len(sq)))
"""
"""
from math import*
s,k = map(int,input().split(" "))
sq = input().split()
score = 0
pol = ""
for i in range(len(sq)):
	if sq[i]>=sq[i-1]:
		score+=1
print(ceil(score/len(sq))+ceil(score/len(sq)))
"""
"""
st=list(input().split('+'))
st.sort()
for i in range(len(st)):
    if i!=len(st)-1:
        print(str(st[i])+'+',end='')
    else:
        print(str(st[i]))
"""
"""
a = input()
up = a.upper()
abc = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
print(abc[abc.find(up[0])]+a[1::])
"""
"""

n= int(input())
k = 0
for i in range(n):
	p = input()
	if p == "++X" or p == "X++":
		k+=1
	elif p == "--X" or p == "X--":
		k-=1
print(k)

"""
"""
import math 

c = 1 

l = int(input()) 

g = "" 

for i in range(l): 

    for s in range(1,l - i + 1): 

     g = g + " " 
    for j in range(0,i + 1): 
     if(i == 0 or j == 0): 
      c = 1 
     else: 
      c = c * (i - j + 1)/j 

     t = c 
     T=0 
     while(t != 0): 
      T = T + 1 
      t = int(math.floor(t/10)) 
     p=0 
     while((p+T)!=4): 
      g = g + " " 
      p=p+1 
     g = g + str(int(math.floor(c))) 
    g = g + "\n" 
print(g)
"""	
"""
 ___        __                            _   _          
|_ _|_ __  / _| ___  _ __ _ __ ___   __ _| |_(_) ___ ___ 
 | || '_ \| |_ / _ \| '__| '_ ` _ \ / _` | __| |/ __/ __|
 | || | | |  _| (_) | |  | | | | | | (_| | |_| | (__\__ \
|___|_| |_|_|  \___/|_|  |_| |_| |_|\__,_|\__|_|\___|___/                                                         
"""
"""
a1 = float(input())
a2 = float(input())
b = (a1**2 + a2**2)
import math
l = math.sqrt(b)
print(l)
"""
"""
n = int(input())
a=list(map(int,input().split(" ")))
b = []
for i in range(len(a)):
    if i%2==0:
        print(a[i],end=' ')
"""
"""
n = int(input())
a=list(map(int,input().split(" ")))
b = []
for i in range(len(a)):
    if a[i]%2==0:
        print(a[i],end=' ')
"""
"""
n = int(input())
a=list(map(int,input().split(" ")))
b = []
for i in range(len(a)):
    if a[i]>0:
        b.append(a[i])
print(len(b))
"""
"""
n = int(input())
a=list(map(int,input().split(" ")))
b = 0
for i in range(1,n):
    if a[i]>a[i-1]:
        b+=1
print(b)
"""
"""
n = int(input())
a=list(map(int,input().split(" ")))
b = 0
for i in range(1,n):
    if a[i]>a[i-1]:
        b+=1
print(b)
"""
"""
n = int(input())
a=list(map(int,input().split(" ")))
b = 0
for i in range(n-1):
        if i == 0:
                pass
        elif  a[i]>a[i-1]and a[i+1]< a[i]:
                b+=1
print(b)
"""
"""
n = int(input())
a=list(map(int,input().split(" ")))
a.reverse()
for i in a:
    print(i,end = " ")
"""
"""
n = int(input())
a=list(map(int,input().split(" ")))
print(max(a))
"""
"""
n = int(input())
a = list(map(int,input().split(" ")))
l = 0
q = []
for i in range(len(a)):
        if a[i] in q:
            pass
        else:
            l +=1
            q.append(a[i])
print(l)
"""
"""
n = int(input())
a = list(map(int,input().split()))
x = int(input())
k =1
for i in range(len(a)):
    k+=1
    if x > a[i]:
        print(i+1)
        exit()
print(k)
"""
"""
a=list(map(int,input().split(" ")))
b = []
for i in range(len(a)):
    if i%2==0:
        print(a[i],end=' ')
"""
"""
a=list(map(int,input().split(" ")))
b = 0
for i in range(len(a)-1):
        if i == 0:
                pass
        elif  a[i]>a[i-1]and a[i+1]< a[i]:
                b+=1
print(b)
"""
"""
a = list(map(int,input().split()))
print(max(a),a.index(max(a)))
"""
"""
ch = list(input()) 
if ch.count("h")>=1 and ch.count("e")>=1 and ch.count("l")>=2 and ch.count("o")>=1 and len(ch)!=53:
	print("YES")
else:
	print("NO")
"""
"""
from decimal import Decimal
x,y = map(Decimal,input().split(" "))
d = 1
while x < y and  x - y < 0.000001 :
    x += x * 70 / 100
    d += 1
print(d)
"""
"""
n = int(input())
abc = "abcdefghijklmnopqrstuvwxyz"
s =""
for i in range(n):
	k,v = map(int,input().split())
	for i in range(k):
		while len(s) <= k:
			s += abc[:v]
		if len(s)>k:
			s = s[:-(len(s)-k)]
	print(s,end="\n")
	s=""		
"""
"""
k = int(input())
l = int(input())
m = int(input())
n = int(input())
d = int(input())
lst = []
lst.append(k)
lst.append(l)
lst.append(m)
lst.append(n)
uron = 0
for i in range(len(lst)):
	if d % lst[i] == 0:
		uron+=lst[i]
print(uron)
"""
"""
n = int(input())
a = list(map(int,input().split()))
ch = 0
nch = 0
for i in range(len(a)):
	if a[i] % 2 == 0:
		ch+=1
	else:
		nch+=1
if ch > nch:
	for i in range(len(a)):
		if a[i] % 2 == 1:
			print(a.index(a[i])+1)
else:
	for i in range(len(a)):
		if a[i]%2==0:
			print(a.index(a[i])+1)
"""
"""
n,t = map(int,input().split())
oc = input()
for i in range (1,n):
	if oc[i]=="B":
		oc[i]=oc[i-1]
print(oc)			
"""
"""
n = int(input())
o = 0
for i in range(n):
	o += ((n-2) - (n % 2))//2
print(o)
"""
sl = input()
abc = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
m=0
b=0
big = ""
for i in range(len(sl)):
	if sl[i]== abc[abc.find(sl[i])]:
			b+=1
	else:
			m +=1
if m>b:
	big += sl.lower()
	print(big)
elif b>m:
	big += sl.upper()
	print(big)
elif b==m:
	big += sl.lower()
	print(big)