Granny’s Puzzle
Time Limit: 1 sec
The Problem
Anna is going meet her grandmother. Her grandma made a puzzle before her house. If Anna wants to go inside she need to solve the puzzle. As you are big hearted you decide to help Anna.
The Puzzle:
There are 5 numbers A, B, C, D, E is given. The numbers will be calculate as (A - B + C – D + E). If the result is divisible by 11 Anna can enter Granny’s house otherwise she can’t.
But if (A - B + C – D + E) = 0 puzzle will break and Granny will come outside to fetch Anna.
The Input
The input will contains several lines. Each line contains 5 integer numbers A, B, C, D and E. All numbers are ranged to -1000 to 1000. Input is terminated by end of file (EOF)
The Output
For each case the output will print “Anna can enter” if she solve the puzzle otherwise “Anna cannot enter”. And if Granny come outside print “Welcome Anna” in a separate line.
Sample Input
2 2 2 2 0
11 1 2 1 0
11 1 2 1 1
Sample Output
Welcome Anna
Anna can enter
Anna cannot enter
Problem Setter: Samia Safa Ahmed