Back
Close
  • 86

Learning Opportunities

This puzzle can be solved using the following concepts. Practice using these concepts and improve your skills.

Statement

 Goal

You have to print the colours of the Front side of a 2×2×2 Rubik’s cube after some moves.
The colours are named by the first letter of each side (Front, Back, Right, Left, Up, Down).
The moves are named the same way if you turn the side clockwise.
For example F moves the Front side clockwise, F' turns it anticlockwise and F2 turns it twice. B turns it clockwise when you look at the Back side.
You won’t be given moves such as F5, B52 or U'3.
Input
The moves in one single line, for example B' possibly with dots (for human readability, you can ignore them).
Output
The colours in two lines, for example:
FF
RR
Constraints
Example
Input
R
Output
FD
FD

A higher resolution is required to access the IDE