Web Design & Development Forum

Web Developers Zone
  • FB
  • TW
  • LND
  • G+

What is the difference between using var keyword or not using var during variable declaration

I have declared javascript variables. I have checked by 2 ways. By giving var keyword and omitting the var keyword. I have not found any difference between these two.   So, using the var keyword is optional. what is the benefit here?  

Posted in: