Reddit Daily Programmer #165 [Hard]