Time limit: 1s
Memory limit: 64MB
Input:
Output:
Task
We say that a natural number is alternating if even digits alternate with odd digits. For example, the numbers are alternating.
Given a natural number , verify whether it is alternating or not.
Input data
The program reads the number from the keyboard.
Output data
The program will print da
(yes in Romanian) if is alternating or nu
(no in Romanian) if it is not alternating.
Constraints and clarifications
- ;
Example 1
stdin
785
stdout
da