코딩
-
[백준 Node.js] 10950번 A+B-3To infinity/Coding Practice 2021. 6. 20. 10:11
2021.06.20 Question 10950번: A+B - 3 두 정수 A와 B를 입력받은 다음, A+B를 출력하는 프로그램을 작성하시오. www.acmicpc.net Answer code let fs = require('fs'); let input = (process.platform === 'linux' ? fs.readFileSync('/dev/stdin').toString() : `5 1 1 2 3 3 4 9 8 5 2 ` ).split('\n'); for(let i=1; i +el); console.log(data[0]+data[1]); let input에 쓴 로직은 업로드 전 VS CODE에서 테스트해보기 위해 짜여진 코드다. 데구리님 블로그에서 참고했다. 백준에서 node.js 입력 방법은 ..