MIRRORED - Mirrored Pairs
The letters b and d are mirror images of each other, as are p and q. No other pairs of letters are mirrors, except for letters like H that are mirrors of themselves, and what’s the interest in a pair that’s just two of the same letter? We refuse to count self-mirrors as mirrored pairs.
Input
Input is a list of lines with two characters on each line. Your program should end immediately when it encounters a line with two spaces.
Output
The first line of output should contain only Ready. For each pair of characters (prior to a pair of spaces), print the line Mirrored pair if the characters are mirrors, otherwise print the line Ordinary pair.
Example
Input: Fr qp HH db pq Output: Ready Ordinary pair Mirrored pair Ordinary pair Mirrored pair
Added by: | Daniel Gómez Didier |
Date: | 2008-11-17 |
Time limit: | 1s |
Source limit: | 50000B |
Memory limit: | 1536MB |
Cluster: | Cube (Intel G860) |
Languages: | All except: ERL JS-RHINO NODEJS PERL6 VB.NET |
Resource: | 2007 PUJ - Circuito de Maratones ACIS / REDIS |