JavaScript Resolver problemas de entrevista

Here are some my selective questions...
Q1. Explain what a callback function is and provide a simple example
Q2. What are the differences between cookie, local storage and session storage
Q3. Write a simple function that returns a boolean indicating whether or not a string is a palindrome.
Q4. How would you check if a number is an integer?
Q5. Implement enqueue and dequeue using only two stacks
Q6. What is a promise. Why do you need a promise?
Q7. How would you use a closure to create a private counter?
Q8. How does the this keyword work? Provide some code examples
Q9. How do you add an element at the begining of an array? How do you delete one from the end?
Q10. Write a recursive function that performs a binary search
...
extra: Why do you need JavaScript? 
SHAM3R