shunfurh
编程介的小学生
2017-11-03 08:53

Happy 2009

  • 2009
  • string
  • acm
  • each

Problem Description
No matter you know me or not. Bless you happy in 2009.

Input
The input contains multiple test cases.
Each test case included one string. There are made up of ‘a’-‘z’ or blank. The length of string will not large than 10000.

Output
For each test case tell me how many times “happy” can be constructed by using the string. Forbid to change the position of the characters in the string. The answer will small than 1000.

Sample Input
hopppayppy happy
happ acm y
hahappyppy

Sample Output
2
1
2

  • 点赞
  • 回答
  • 收藏
  • 复制链接分享

1条回答

为你推荐

换一换