Notice
Recent Posts
Recent Comments
Link
์ผ | ์ | ํ | ์ | ๋ชฉ | ๊ธ | ํ |
---|---|---|---|---|---|---|
1 | 2 | |||||
3 | 4 | 5 | 6 | 7 | 8 | 9 |
10 | 11 | 12 | 13 | 14 | 15 | 16 |
17 | 18 | 19 | 20 | 21 | 22 | 23 |
24 | 25 | 26 | 27 | 28 | 29 | 30 |
Tags
- emotion RSC
- ๋ฐฑ์ค 2108 ์๋ฐ์คํฌ๋ฆฝํธ
- suspense ๋์์๋ฆฌ
- ์ต์ ๋์ฒด์ด๋
- js
- ์ค์ฝํ
- app router emotion
- js ์ค์ฝํ
- ์๋ฐ์คํฌ๋ฆฝํธ ์ค์ฝํ
- ๊ตฌ๋ฆํค ์ฑ๋ฆฐ์ง ํ๊ณ
- ๋ฐฑ์ค 1339๋ฒ ์๋ฐ์คํฌ๋ฆฝํธ
- ๋ฆฌ์กํธ์ฟผ๋ฆฌ suspense
- suspense react-query
- ๋ฐฑ์ค 1339๋ฒ js
- ๊ตฌ๋ฆํค ์ฑ๋ฆฐ์ง
- ํ๋ก๊ทธ๋๋จธ์ค ๋ฌธ์์ด ์์ถ
- ์๋ฐ์คํฌ๋ฆฝํธ ๋ฌธ์์ด ์์ถ
- js ๋ฌธ์์ด ์์ถ
- suspense ๋น๋๊ธฐ
- js ๊ฑฐ๋ฆฌ๋๊ธฐ ํ์ธํ๊ธฐ
- TypeError: createContext only works in Client Components. Add the "use client" directive at the top of the file to use it. Read more:
- suspense ๋ณ๋ชฉํ์
- ํ๋ก๊ทธ๋๋จธ์ค ๊ฑฐ๋ฆฌ๋๊ธฐ ํ์ธํ๊ธฐ
- ๋ฐฑ์ค 2108 nodejs
- ๋ฐฑ์ค 1339๋ฒ nodejs
- ๊ตฌ๋ฆํค
- next13 emotion
- ์ฌ์ฉ์ฑ ๊ฐ์
- ์นด์นด์ค ์ฝํ
- emtion app router
Archives
- Today
- Total
Lennon FE
[๋ฐฑ์ค 10870๋ฒ] ํผ๋ณด๋์น ์5 - ์๋ฐ์คํฌ๋ฆฝํธ(nodejs) ๋ณธ๋ฌธ
๐ฅ Algorithm/Baekjoon
[๋ฐฑ์ค 10870๋ฒ] ํผ๋ณด๋์น ์5 - ์๋ฐ์คํฌ๋ฆฝํธ(nodejs)
Lennon 2022. 1. 18. 19:04728x90
๋ฐ์ํ
https://www.acmicpc.net/problem/10870
const fs = require('fs');
let input = +fs.readFileSync('dev/stdin').toString().trim();
function fibonacci(num) {
if (num <= 1) return num;
return fibonacci(num - 1) + fibonacci(num - 2);
}
console.log(fibonacci(input));
num์ด 1๋ณด๋ค ์์ ๋ ์ข ๋ฃ์กฐ๊ฑด์ ๊ฑด๋ค.
ํด๋น ๋ก์ง์์ num์ผ๋ก 5๋ฅผ ๋์ ํ๋ฉด fibo[4]-fibo[3] --> ์ฐ์์ ์ผ๋ก fibo[0]๊น์ง ๊ฐ๋ค๊ฐ ํจ์๊ฐ ๋๋๊ณ ๊ฐ์ ๋ชจ๋ ๋ํด ์ถ๋ ฅ๋ ๊ฒ์ด๋ค.
728x90
๋ฐ์ํ
'๐ฅ Algorithm > Baekjoon' ์นดํ ๊ณ ๋ฆฌ์ ๋ค๋ฅธ ๊ธ
[๋ฐฑ์ค 2751๋ฒ] ์ ์ ๋ ฌํ๊ธฐ2 - ์๋ฐ์คํฌ๋ฆฝํธ(nodejs) (0) | 2022.01.19 |
---|---|
[๋ฐฑ์ค 7568๋ฒ] ๋ฉ์น - ์๋ฐ์คํฌ๋ฆฝํธ(nodejs) (0) | 2022.01.18 |
[๋ฐฑ์ค 10872๋ฒ] ํฉํ ๋ฆฌ์ผ - ์๋ฐ์คํฌ๋ฆฝํธ(nodejs) (0) | 2022.01.18 |
[๋ฐฑ์ค 9020๋ฒ] ๊ณจ๋๋ฐํ์ ์ถ์ธก - ์๋ฐ์คํฌ๋ฆฝํธ(nodejs) (0) | 2022.01.18 |
[๋ฐฑ์ค 4948๋ฒ] ๋ฒ ๋ฅดํธ๋ ๊ณต์ค - ์๋ฐ์คํฌ๋ฆฝํธ(nodejs) (0) | 2022.01.17 |
Comments