const main = (input) => {
  const s = input.trim()

  return console.log(s[s.length-1] === 's' ? s+'es' : s+'s')
}

process.env.MYTEST
  ? (process.env.MYTEST === 'test' ? test() : main(require('fs').readFileSync('dev/stdin', 'utf8')))
  : main(require('fs').readFileSync('/dev/stdin', 'utf8'))