Plural Form SOLUTION AtCoder Beginner Contest 179

Plural Form SOLUTION

Problem Statement

In the Kingdom of AtCoder, individuals utilize a language called Taknese, which utilizes lowercase English letters. In Taknese, the plural type of a thing is spelled dependent on the accompanying guidelines:

On the off chance that a thing’s solitary structure doesn’t end with s, affix s to the furthest limit of the particular structure.

On the off chance that a thing’s solitary structure closes with s, affix es to the furthest limit of the particular structure.

You are given the particular structure S of a Taknese thing. Yield its plural structure.

Imperatives S is a line of length 1 between 1000 , comprehensive. S contains just lowercase English letters.

Info

Info is given from Standard Input in the accompanying organization:

S

Yield

Print the plural type of the given Taknese word.

Test Input 1

Duplicate

apple

Test Output 1

Duplicate

apples

apple closes with e, so its plural structure is apples.

Test Input 2

Duplicate

transport

Test Output 2

Duplicate

transports

transport closes with s, so its plural structure is transports.

Test Input 3

Duplicate

box

Test Output 3

Duplicate

boxs

Related :

Leave a Comment