Accept an input with 10 letters If the letter W contains five or more characters

Accept an input with 10 letters If the letter W contains five or more characters, then output "OK" and "NG" if the number is less than five. (Note: The 10 letters contain space between each other.

The letter contained in the 10 letters is only S or W)

Example (1) If the input value is W W W W W S W W S W, the output is 5 or more, so the output is OK.

Example (2) If the input value is W W S S S W S W S S, if the input value is less than 5, then the output is NG.

0   0
Hein Htet

Please rotate your device

We don't support landscape mode on your device. Please rotate to portrait mode for the best view of our site