| CodeRams Practice Problem Archive |
|---|
| Finished |
You consider a string to be a diverse string if every pair of adjacent characters are different. For example coderams is a diverse string, while hello is not.
Given a string, figure out whether or not it is a diverse string.
The only line of input contains a single string, not containing spaces.
If the string is a diverse string, output "YES" (no quotes). Otherwise, output "NO" (no quotes).
coderamsclub
YES
helloworld
NO
| Name |
|---|


