This is a solution to r/dailyprogrammer #115 easy