Skip to content

Commit 55d088d

Browse files
authored
Update README.md
1 parent 4544d1e commit 55d088d

File tree

1 file changed

+34
-23
lines changed

1 file changed

+34
-23
lines changed

README.md

Lines changed: 34 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,35 @@
1-
**Q1. Is javascript a dynamically typed language or a statically typed language ?**
2-
Javascript is a dynamically typed language.
3-
It means all type checks are done at run time ( When program is executing )
4-
So, we can just assign anything to the variable and it works fine.
1+
## JavaScript Basics
52

6-
let a;
7-
a = 0;
8-
console.log(a) // 0
9-
a = "Hello"
10-
console.log(a) // "Hello"
11-
12-
**Q2. What are the different datatypes in javascript ? (Most asked)**
13-
Primitive datatypes:
14-
String
15-
number
16-
boolean
17-
null
18-
undefined
19-
Bigint
20-
symbol
21-
Non-Primitive datatypes:
22-
Array
23-
Object
24-
Date
3+
### Index
4+
1. [Is JavaScript a dynamically typed language or a statically typed language?](#q1-is-javascript-a-dynamically-typed-language-or-a-statically-typed-language)
5+
2. [What are the different datatypes in JavaScript?](#q2-what-are-the-different-datatypes-in-javascript-most-asked)
6+
7+
### Q1. Is JavaScript a dynamically typed language or a statically typed language?
8+
JavaScript is a dynamically typed language. It means all type checks are done at runtime (when the program is executing). So, we can just assign anything to the variable and it works fine.
9+
10+
```javascript
11+
let a;
12+
a = 0;
13+
console.log(a); // 0
14+
a = "Hello";
15+
console.log(a); // "Hello";
16+
```
17+
[Back to Top](#javascript-basics)
18+
19+
### Q2. What are the different datatypes in JavaScript? (Most asked)
20+
21+
**Primitive datatypes:**
22+
- String
23+
- Number
24+
- Boolean
25+
- Null
26+
- Undefined
27+
- Bigint
28+
- Symbol
29+
30+
**Non-Primitive datatypes:**
31+
- Array
32+
- Object
33+
- Date
34+
;
35+
[Back to Top](#javascript-basics)

0 commit comments

Comments
 (0)