Skip to content

Commit

Permalink
JavaScript_intro
Browse files Browse the repository at this point in the history
  • Loading branch information
LiJell committed May 13, 2022
1 parent 7e4c0d6 commit 84cc566
Show file tree
Hide file tree
Showing 5 changed files with 75 additions and 0 deletions.
49 changes: 49 additions & 0 deletions Front-End/JavaScript/Booleans.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
## true

- 1

---



## false

- 0

---



## null

- null은 자연스럽게 생기지 않음
- variable 안에 어떤것도 없다는 것을 확실히 알려주기 위해 씀

```javascript
const amIFat= null;
// amIFat에 아무것도 채워지지 않은 null 채우는것을 의미
let something;
console.log(amIFat);
```

![image-20220513180240250](C:\Users\hanju\TIL\image.assets\image-20220513180240250.png)

---



## Undefined

- something이라는 var을 만들었지만, 값을 주지 않은 상태
- 메모리 안에 공간은 있지만, 값은 없는 상태


```javascript
const amIFat= null;
let something;
// something이라는 var을 만들었지만, 값을 주지 않은 상태
// 메모리 안에 공간은 있지만, 값은 없는 상태
console.log(something);
```

![image-20220513180337087](C:\Users\hanju\TIL\image.assets\image-20220513180337087.png)
26 changes: 26 additions & 0 deletions Front-End/JavaScript/const_let_difference.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
## const

- cannot be changed

## let

- can be changed later



```javascript
const a = 5;
const b = 2;
let myName = "Hanju";

console.log(a + b);
console.log(a * b);
console.log(a / b);
console.log("Hello! " + myName);

myName = "LiJell";

console.log("your new name is " + myName);
```

![image-20220513175522806](C:\Users\hanju\TIL\image.assets\image-20220513175522806.png)
Binary file added image.assets/image-20220513175522806.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added image.assets/image-20220513180240250.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added image.assets/image-20220513180337087.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 84cc566

Please sign in to comment.