Robot Inventor to Teach Algorithms