changed JS to the one with comments about changes
Updated solving Daniels feedback