A higher resolution is required to access the IDE
- 439
Learning Opportunities
This puzzle can be solved using the following concepts. Practice using these concepts and improve your skills.
Statement
Goal
A 2×2×2 Rubik's cube is quite complicated. In this puzzle, we will focus on the mono-cube, the 1×1×1 Rubik's cube!You are given a set of rotations and two faces. Apply the rotations to the cube and locate the two faces after the rotations.
Face notation
Rotation notation
A rotation without the prime symbol
A rotation with the prime symbol
Example 1
Means: rotate cube clockwise on
Answer: Output
Example 2
Means: rotate cube clockwise on
Answer: Output
Input
Line 1: Space-separated rotations in xyz notation.
Line 2: Initial direction of face1 the first queried face.
Line 3: Initial direction of face2 the second queried face.
Line 2: Initial direction of face1 the first queried face.
Line 3: Initial direction of face2 the second queried face.
Output
Line 1: Direction of face1 after the rotations.
Line 2: Direction of face2 after the rotations.
Line 2: Direction of face2 after the rotations.
Constraints
1 ≤ length of rotations ≤ 100
Example
Input
z D L
Output
L U
A higher resolution is required to access the IDE