Update hw2.js

Basics for the 'hexed' function, takes the arguments, and sets the variables 'difficulty' and 'turns' accordingly.