Problem A

Anders talks in the Swedish dialect of östgötska. Unfortunately, this makes it somewhat hard to get a programming job in the Swedish capital of Stockholm. The trendy Stockholm hipsters only accept applicants speaking the standard Swedish dialect, rikssvenska.

To increase his chances of passing interviews, he wishes to practice talking rikssvenska. To help him with this, he wants you to write a program that can determine whenever he accidentally reverts to speaking östgötska.

A simple way of determining if a sentence is written in östgötska is if at least $40\% $ of the words in the sentence contains the letter ä. For simplicity, this is encoded as the letter combination ae (meaning any appearance of the substring ae is to be regarded as an occurrence of the letter ä).


The first and only line of input contains a sequence of space-separated words. Each word consists only of letters a-z. There are at most $100$ words, and each word contains at most $15$ letters a-z (meaning that the ae combination counts as two letters for this limit).


Output “dae ae ju traeligt va” if the input sentence is in östgötska, otherwise output “haer talar vi rikssvenska”.

Sample Input 1 Sample Output 1
dae ae ju traeligt va
dae ae ju traeligt va
Sample Input 2 Sample Output 2
haer talar vi rikssvenska
haer talar vi rikssvenska
CPU Time limit 1 second
Memory limit 1024 MB
Statistics Show
License Creative Commons License (cc by-sa)

Please log in to submit a solution to this problem

Log in