solution for 1.js