title: Global variable to local variable in JavaScript
body: <p>I know global variables are created when they are declared outside a function (says <a href="https://en.wikipedia.org/wiki/W3Schools" rel="nofollow noreferrer">W3Schools</a>).</p>
  <p>If I create a global variable and edit it in a function, does it become local? Does the new value given by the function become the global value?</p>