Open ahribori opened 5 years ago
const staircase = n => {
for (let i = 0; i < n; i++) {
let line = '';
for (let j = n; j >= 0; j--) {
if (i >= j) {
line += '#';
} else {
line += ' ';
}
}
console.log(line);
}
};
https://www.hackerrank.com/challenges/staircase/problem
샵찍기 문제
이런 모양으로 찍어야 된다.