CS/Data Structure & algorithm
문제https://www.acmicpc.net/problem/4889 풀이1. Node.js(fs)const fs = require('fs');const input = fs.readFileSync('/dev/stdin').toString().trim().split('\n');const numCases = parseInt(input[0]);function evaluateExpression(expr) { const stack = []; for (let i = 0; i 2. Node.js(readLine)const readline = require('readline');const rl = readline.createInterface({ input: process.stdin, output..
CS/Data Structure & algorithm
문제https://www.acmicpc.net/problem/4466 풀이1. Node.js(fs)const fs = require('fs');const input = fs.readFileSync('/dev/stdin').toString().trim().split('\n');const numCases = parseInt(input[0]);function evaluateExpression(expr) { const stack = []; for (let i = 0; i 2. Node.js(readLine)const readline = require('readline');const rl = readline.createInterface({ input: process.stdin, output..
CS/Data Structure & algorithm
문제https://www.acmicpc.net/problem/4227풀이1. Node.js(fs)const fs = require('fs');const input = fs.readFileSync('/dev/stdin').toString().trim().split('\n');function evaluateSmeech(expr) { if (!isNaN(expr)) { return parseFloat(expr); } expr = expr.slice(1, -1); // 바깥쪽 괄호 제거 let p = parseFloat(expr); let rest = expr.slice(expr.indexOf(' ') + 1); let openBrackets = 0; l..
CS/Data Structure & algorithm
문제https://www.acmicpc.net/problem/3986풀이1. Node.js(fs)const fs = require('fs');const input = fs.readFileSync('/dev/stdin').toString().trim().split('\n');const N = parseInt(input[0]);let goodWordCount = 0;function isGoodWord(word) { const stack = []; for (let char of word) { if (stack.length > 0 && stack[stack.length - 1] === char) { stack.pop(); } else { ..
단축키
내 블로그
내 블로그 - 관리자 홈 전환 |
Q
Q
|
새 글 쓰기 |
W
W
|
블로그 게시글
글 수정 (권한 있는 경우) |
E
E
|
댓글 영역으로 이동 |
C
C
|
모든 영역
이 페이지의 URL 복사 |
S
S
|
맨 위로 이동 |
T
T
|
티스토리 홈 이동 |
H
H
|
단축키 안내 |
Shift + /
⇧ + /
|
* 단축키는 한글/영문 대소문자로 이용 가능하며, 티스토리 기본 도메인에서만 동작합니다.