const fs = require('fs');
const input = fs.readFileSync('/dev/stdin').toString().trim().split('\n').map(n=> n.trim());
const [n, x] = input[0].split(' ').map(n=> Number(n));
const A = input[1].split(' ').map(n => Number(n));
let smallerThanX ='';
for(let i = 0; i < n; i++){
if(A[i] < x){
smallerThanX += A[i] + '\n';
}
}
console.log(smallerThanX);
'TIL(Today I learned) > 2. 알고리즘_백준' 카테고리의 다른 글
백준 1110번 문제_node.js (0) | 2022.07.20 |
---|---|
백준 10952 문제_node.js (0) | 2022.07.18 |
백준 2439번_node.js (0) | 2022.07.18 |
백준 2438문제_node.js (0) | 2022.07.18 |
백준 11022 문제_node.js (0) | 2022.07.18 |