LOADING

加载过慢请开启缓存,浏览器默认开启

daily 1

2023/9/9

CF 59A

#include<iostream>
#include<string>
using namespace std;
int main(){
    string s;
    while(cin>>s){
        int low=0,up=0;
        for(int i=0;i<s.length();++i){
            if(s[i]>=65&&s[i]<=90)  ++up;
            else if(s[i]>=97&&s[i]<=122)    ++low;
        }
        if(low>=up){
            for(int i=0;i<s.length();++i){
                if(s[i]>=65&&s[i]<=90)
                    s[i]+=32;
            }
        }
        else{
            for(int i=0;i<s.length();++i){
                if(s[i]>=97&&s[i]<=122)
                    s[i]-=32;
            }
        }
        cout<<s<<'\n';
    }
    return 0;
}