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:
# vowels = ["a", "o", "y", "e", "u", "i"]
# s = list(input().lower())
# ans = ""
# for i in vowels:
#     if i in s:
#         while i in s:
#             s.remove(i)
# for i in range(len(s)):
#     s[i] = "." + s[i]
# print(ans.join(s))


# n = int(input())
# ans = 0
# for i in range(n):
#
#     s = input()
#     if "-" in s:
#         ans -= 1
#     if "+" in s:
#         ans += 1
#
#
# print(ans)

# s1 = input().lower()
# s2 = input().lower()
# isequal = False
# for i in range(len(s1)):
#     if s1[i] > s2[i]:
#         print("1")
#         isequal = True
#         break
#     if s2[i] > s1[i]:
#         print("-1")
#         isequal = True
#         break
# if not isequal:
#     print("0")

# s = list(input())
# not_dangerous = False
# for i in range(len(s)):
#     if i != len(s) - 1:
#         j = 0
#         while i + j <= len(s) - 1 and s[i] == s[i + j]:
#             j += 1
#         if j >= 7:
#             print("YES")
#             not_dangerous = True
#             break
# if not not_dangerous:
#     print("NO")


# s = list(input())
# ans = ""
# while "+" in s:
#     s.remove("+")
# s.sort()
# for i in range(len(s)):
#     if i != len(s) - 1:
#         ans += s[i] + "+"
#     else:
#         ans += s[i]
#
# print(ans)


# s = list(input())
# capital_letter = s[0]
# s = s[1:]
# ans = ""
# capital_letter = str(capital_letter).capitalize()
# s = [capital_letter] + s
# print(ans.join(s))

# import math
# matrix = []
# for i in range(5):
#     matrix.append(list(map(int, input().split())))
#     if 1 in matrix[i]:
#         (x, y) = i, matrix[i].index(1)
#
# print(str(int(math.fabs(x - 2) + math.fabs(y - 2))))

# input()
# s = list(input())
# ans = []
# counter = 0
# for i in range(len(s) - 1):
#     if s[i] == s[i + 1]:
#         counter += 1
#     else:
#         ans.append(s[i + 1])
#
# print(counter)

# s = set(list(input()))
# print("CHAT WITH HER!" if len(s) % 2 == 0 else "IGNORE HIM!")

# input()
# groups = list(map(int, input().split()))
# group_type = [0, 0, 0, 0]
# ans = 0
# for i in groups:
#     group_type[i - 1] += 1
# ans += group_type[-1]
#
# group_type[-1] = 0
#
# ans += min(group_type[0], group_type[2])
#
# if group_type[0] < group_type[2]:
#     group_type[2] = group_type[2] - group_type[0]
#     group_type[0] = 0
# elif group_type[0] == group_type[2]:
#     group_type[0] = 0
#     group_type[2] = 0
# else:
#     group_type[0] = group_type[0] - group_type[2]
#     group_type[2] = 0
#
# ans += group_type[1] // 2
#
# group_type[1] = group_type[1] % 2
#
# if group_type[0]:
#     taxi = group_type[1] * 2
#     for i in range(group_type[0]):
#         if taxi == 4:
#             ans += 1
#             taxi = 0
#         taxi += 1
#
#     if taxi:
#         ans += 1
# else:
#     ans += group_type[2]
#     if group_type[1]:
#         ans += 1
#
# print(ans)

# n = int(input())
# minimum_capacity = 0
# io_list = []
# io_recorder = 0
# for i in range(n):
#     io_list.append(tuple(map(int, input().split())))
#     if i == 0:
#         minimum_capacity = io_list[0][1]
#     io_recorder -= io_list[i][0]
#     io_recorder += io_list[i][1]
#     if minimum_capacity < io_recorder:
#         minimum_capacity = io_recorder
# print(minimum_capacity)


# n, index = map(int, input().split())
# value_list = list(map(int, input().split()))
# solved = False
# pointer = 0
# for i in range(len(value_list) + 1):
#     if pointer == index - 1:
#         print("YES")
#         solved = True
#         break
#     if pointer < len(value_list):
#         pointer += value_list[pointer]
# if not solved:
#     print("NO")

# import math
#
# n = int(input())
# list1 = list(map(int, input().split()))
# m = int(input())
# list2 = list(map(int, input().split()))
#
# graph = dict()
#
# for i in list1:
#     graph[i] = []
# if n > m:
#     n, m = m, n
#     list1, list2 = list2, list1
#
# for i in list1:
#     for j in list2:
#         if math.fabs(i - j) == 1:
#             graph[i].append(j)
#
# value_list = sorted(list(graph.values()))
# # while graph:
# for i in value_list:
#

# k, n, w = map(int, input().split())
# cost = 0
# for i in range(w):
#     cost += (i + 1) * k
# if cost - n > 0:
#     print(cost - n)
# else:print("0")

# n = int(input())
# xi = 0
# yi = 0
# zi = 0
# for i in range(n):
#     xyz = list(map(int, input().split()))
#     xi += xyz[0]
#     yi += xyz[1]
#     zi += xyz[2]
# if xi == yi == zi == 0:
#     print("YES")
# else:
#     print("NO")

#
# import sys
# s = input()
# print("YES" if "H" in s or "Q" in s or "9" in s else (print("NO"), sys.exit()))

# s = input()
# is_changed = False
# if s.isupper():
#     print(s.lower())
#     is_changed = True
#
# if ord(s[0]) > 96 and (s[1:].isupper() or len(s) == 1):
#     print(s[0].upper() + s[1:].lower())
#     is_changed = True
# if not is_changed:False
#     print(s)


# ans = 0
# for i in range(int(input())):
#     p, q = map(int, input().split())
#     if q - p >= 2:
#         ans += 1
# print(ans)


# n, t = map(int, input().split())
# main_list = list(input())
# for i in range(t):
#     j = 0
#     while j < n:
#         if j != n - 1:
#             if main_list[j] == "B" and main_list[j + 1] == "G":
#                 main_list[j], main_list[j + 1] = main_list[j + 1], main_list[j]
#                 j += 1
#         j += 1
# print("".join(main_list))


# ans = 0
# number = list(map(int, list(input())))
# for i in number:
#     if i == 4 or i == 7:
#         ans += 1
#     if ans > 7:
#         break
# if ans == 7 or ans == 4:
#     print("YES")
# else:
#     print("NO")


# def odd_sum (n):
#     return ((1 + n)/2) * ((n // 2) + 1)
#
#
# def even_sum (n):
#     return ((2 + n) / 2) * (n // 2)
#
#
# n = int(input())
# if n % 2 == 1:
#     # print(int(-odd_sum(n) + even_sum(n - 1)))
#     print(odd_sum(n))
#
# else:
#
#     # print(int(-odd_sum(n - 1) + even_sum(n)))
#     print(even_sum(n))


# s1 = input()
# s2 = input()
# is_solved = False
# if len(s1) != len(s2):
#     is_solved = True
# if not is_solved:
#     for i in range(len(s1)):
#         if s1[i] != s2[len(s1) - 1 - i]:
#             is_solved = True
#             break
# if is_solved:
#     print("NO")
# else:
#     print("YES")

# n = int(input())
# first_time = True
# ans = 0
# income_list = input().split()
# for i in range(n):
#     j = 0
#     while i + j < n - 1:
#         if not (income_list[i + j] < income_list[i + j + 1]):
#             break
#         j += 1
#         # print(j)
#     if j > 0:
#         j += 1
#     if first_time:
#         ans = j
#         first_time = False
#     else:
#         if j > ans:
#             ans = j
#
# print(ans)
#


# n = int(input())
# step_list = input().split()
# is_running = True
# for i in range(n):
#
#
#     while is_running:
#         if temp > step_list[i + j]:
#             is_running = False
#         temp = step_list[i + j]

# import math
# for i in range(1000000000):
#     for j in range(10000000000):
#         print(i, j, i**j, j**i, math.factorial(i), math.factorial(j))

# length = int(input())
# input_string_list = list(map(int, input().split()))
# first_time = True
# temp_list = []
# ans = 0

# temp_list.append(1)
# for i in range(1, length):
#     temp = temp_list[-1]
#     if input_string_list[i] >= input_string_list[i - 1]:
#         temp_list.append(temp + 1)
#     else:
#         temp_list.append(1)

# print(max(temp_list))


# n = int(input())
# main_list = list(map(int, input().split()))
# main_dict = dict()
# ans = ""
# for i in range(1, len(main_list) + 1):
#     main_dict[main_list[i - 1]] = i
# # print(main_dict)
# for i in range(1, n + 1):
#     ans += str(main_dict[i]) + " "
# print(ans[:-1])

# length = int(input())
# input_string_list = list(map(int, input().split()))
# length_list = []
# length_list.append(1)
# for i in range(length - 1):
#     if input_string_list[i] <= input_string_list[i + 1]:
#         length_list[-1] += 1
#     else:
#         length_list.append(1)
# print(max(length_list))
input_string = input()
input_string_list = list(input_string)
input_string_length = len(input_string_list)
lower_count = 0
for i in range(input_string_length):
    if ord(input_string_list[i]) > 96:
        lower_count += 1
lower_count = float(lower_count)
if lower_count >= input_string_length / 2:
    print(input_string.lower())
else:
    print(input_string.upper())