n=(eval(input()))

if n[-1]== 's':

    print((n+"es"))

else:

    print((n+'s'))











n=(eval(input()))

if n.endswith('s'):

    print((n+'es'))

else:

    print((n+'s'))











n = eval(input())
if n[-1] == "s":
    print((n + "es"))
else:
    print((n + "s"))

n = eval(input())
if n.endswith("s"):
    print((n + "es"))
else:
    print((n + "s"))

-if n[-1] == "s": +if n.endswith("s"):