How to take input in JavaScript