Advertisement
sissou123

Untitled

Mar 22nd, 2022
831
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. JavaScript Algorithms and Data Structures
  2. Basic JavaScript
  3. Declare JavaScript Variables
  4. In computer science, data is anything that is meaningful to the computer. JavaScript provides eight different data types which are undefined, null, boolean, string, symbol, bigint, number, and object.
  5.  
  6. For example, computers distinguish between numbers, such as the number 12, and strings, such as "12", "dog", or "123 cats", which are collections of characters. Computers can perform mathematical operations on a number, but not on a string.
  7.  
  8. Variables allow computers to store and manipulate data in a dynamic fashion. They do this by using a "label" to point to the data rather than using the data itself. Any of the eight data types may be stored in a variable.
  9.  
  10. Variables are similar to the x and y variables you use in mathematics, which means they're a simple name to represent the data we want to refer to. Computer variables differ from mathematical variables in that they can store different values at different times.
  11.  
  12. We tell JavaScript to create or declare a variable by putting the keyword var in front of it, like so:
  13. for more:https://www.clictune.com/ey5u
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement