0% found this document useful (0 votes)
1 views

JS1 ClassNotes

JavaScript (JS) is a programming language used to instruct computers. The document covers setting up VS Code, writing basic JS code using console.log, and explains variable rules and types. It also introduces variable declarations with let, const, and var, and includes practice questions for creating objects.

Uploaded by

rashidk
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
1 views

JS1 ClassNotes

JavaScript (JS) is a programming language used to instruct computers. The document covers setting up VS Code, writing basic JS code using console.log, and explains variable rules and types. It also introduces variable declarations with let, const, and var, and includes practice questions for creating objects.

Uploaded by

rashidk
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 9

What is

JavaScript
JS is a programming language. We use it to give instructions to
the computer.

Input Comput Output


(code) er
Setting up VS code
It is a free & popular code editor by
Microsoft
Our 1st JS Code
Console.log is used to log (print) a message to
the console

console.log(“BCA ”);
Variables in JS
Variables are containers for
data

radiu
s

14

memory
Variable
Rules
Variable names are case sensitive; “a” & “A” is different.

Only letters, digits, underscore( _ ) and 3 is allowed. (not

even space) Only a letter, underscore( _ ) or 3 should be

1st character.

Reserved words cannot be variable names.


let, const &
var
var : Variable can be re-declared & updated. A global scope
variable.

let : Variable cannot be re-declared but can be updated. A block

scope variable. const : Variable cannot be re-declared or updated.

A block scope variable.


Data Types in JS
Primitive Types : Number, String, Boolean, Undefined, Null,
BigInt, Symbol
Let‘s Practice
Qs1. Create a const object called “product” to store information shown
in the picture.
Let‘s Practice
Qs2. Create a const object called “profile” to store information shown
in the picture.

You might also like