Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

staircase

// Staircase detail
// drawing a staircase with the best case
let n = 5; // you can change value of (n)
for (let i = 1; i <= n; i++) {
    console.log("#".repeat(i).padStart(n));
}
Comment

PREVIOUS NEXT
Code Example
Javascript :: Javascript Encapsulation Inheritance Polymorphism Composition 
Javascript :: replace text content with element node 
Javascript :: module imports renaming 
Javascript :: datatables data in one line 
Javascript :: change button text dynamically angular 6 
Javascript :: Second Simplest Promise Example 
Javascript :: auto load in element show 
Javascript :: react antd modal with quill 
Javascript :: Object.entries() To Use For Of On JSON 
Javascript :: 20 most common question in javascript 
Javascript :: Use Dynamic Scales 
Javascript :: 1--Reverse Bits Algo 
Javascript :: Update A Value In ExpressJS/MongoDB 
Javascript :: JavaScript HTMLCollection Object 
Javascript :: livewire multiple root elements detected. this is not supported 
Javascript :: Calculating with Functions 
Javascript :: expact 
Javascript :: Backbone Set Model In View 
Javascript :: Check if a number starts with another number or not js 
Javascript :: Initialize View With Collection Backbone 
Javascript :: update excel file in react js using sheetjs 
Javascript :: callback function jquery 
Javascript :: js 
Javascript :: .reverse javascript string 
Javascript :: vuejs methods 
Javascript :: sweetalert2 redirect after ok 
Javascript :: how to reverse sort lines in javascript 
Javascript :: exit react native app 
Javascript :: JavaScript built-in methods 
Javascript :: javascript for...of with Maps 
ADD CONTENT
Topic
Content
Source link
Name
2+9 =