Skip to content

Comments

Staircase solution#20

Open
fogha wants to merge 9 commits intojsacademyio:masterfrom
fogha:staircase
Open

Staircase solution#20
fogha wants to merge 9 commits intojsacademyio:masterfrom
fogha:staircase

Conversation

@fogha
Copy link

@fogha fogha commented May 21, 2020

No description provided.

const stairCase = (n) => {

for(let i = 0; i <= n; i++) {
console.log("\x20".repeat(n - i) + "#".repeat(i))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Solution is not correct. It prints an extra space everytime. Please check that

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants