7402: Happy or Sad(Problem J2)

内存限制:128 MB 时间限制:1.000 S
评测方式:文本比较 命题人:
提交:0 解决:0

题目描述

We often include emoticons in our text messages to indicate how we are feeling. The three consecutive characters :-) indicate a happy face and the three consecutive characters :-( indicate a sad face. Write a program to determine the overall mood of a message.

输入

There will be one line of input that contains between 1 and 255 characters.

输出

The output is determined by the following rules: • If the input line does not contain any happy or sad emoticons, output none. • Otherwise, if the input line contains an equal number of happy and sad emoticons, output unsure. • Otherwise, if the input line contains more happy than sad emoticons, output happy. • Otherwise, if the input line contains more sad than happy emoticons, output sad

样例输入 复制

How are you :-) doing :-( today :-)?

样例输出 复制

happy

来源/分类