Learn Introductory JavaScript by Building a Pyramid Generator - Step 55

Tell us what’s happening:

I’m sorry… i truly don’t understand and why i have to do it in this way. I don’t know what to write.

Your code so far

const character = "#";
const count = 8;
const rows = [];

function padRow(name) {
  return name;
}

// User Editable Region

let a = 5;
let b = 10;

function addTwoNumbers(a,b){
return a+b;

}
const sum = addTwoNumbers();

console.log(sum);



// User Editable Region


const call = padRow("CamperChan");
console.log(call);


for (let i = 0; i < count; i = i + 1) {
  rows.push(character.repeat(i + 1))
}

let result = ""

for (const row of rows) {
  result = result + row + "\n";
}

console.log(result);

Your browser information:

User Agent is: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:132.0) Gecko/20100101 Firefox/132.0

Challenge Information:

Learn Introductory JavaScript by Building a Pyramid Generator - Step 55

here you need to give the two arguments to the function

1 Like