import Foundation

let a = readLine() 
let str = String(UTF8String: a!)!


var mone = 0
var newString = ""
for i in str.characters {
    newString.appendContentsOf(String(i))
    if mone == 3 {
        newString.appendContentsOf(String(" "))
    }
    mone++
    
}

print(newString.uppercaseString)