Jump to content

Thomas Garrod

Members
  • Posts

    1
  • Joined

  • Last visited

Thomas Garrod's Achievements

Newbie

Newbie (1/7)

0

Reputation

  1. I am struggling with the JavaScript tutorial. Can someone please help me nail down the definition of a literal? The tutorial tells us "The JavaScript syntax defines two types of values: Fixed values and variable values." It then informs us that "...fixed values are called literals and variable values are called variables." I can memorize that, but I'm not sure what it means. Does this means that a variable called age has a literal value? For example, when I fill a form asking for my first name, assuming it is linked to a database variable called FirstName, Thomas would be a literal? What if the variable is age, would the number entered by a fixed variable or literal, even though that number will change in a few months? Is a variable value then the conceptual container that holds literals (and is a null value a literal)? So, is fair to say that a literal can be numbers (with or without decimals) or strings?
×
×
  • Create New...