A higher resolution is required to access the IDE
- 65
Learning Opportunities
This puzzle can be solved using the following concepts. Practice using these concepts and improve your skills.
Statement
Goal
When written with digits, some digits may still read when flipped (Once flipped, some integers remain identical like
Given an integer n, say whether it is "stunning" or not, then find the next "stunning number"...
-- -- -- -- -- -- -- --
| | | | | | | | | | | | | |
-- -- -- -- -- -- --
| | | | | | | | | | | | |
-- -- -- -- -- -- --
-- -- -- -- -- -- --
| | | | | | | | | | | | |
-- -- -- -- -- -- --
| | | | | | | | | | | | | |
-- -- -- -- -- -- -- --
Even if the number
Input
n an integer
Output
Line 1: true if n is a "stunning number", false otherwise
Line 2: the next "stunning number".
Line 2: the next "stunning number".
Constraints
Example
Input
69
Output
true 88
A higher resolution is required to access the IDE