Liliana797979

NxN matrix - fundamentals

Jun 11th, 2021
147
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function solve(num) {
  2.     let res = "";
  3.  
  4.     for (let i = 1; i <= num; i++) {
  5.       res += num + " ";
  6.     }
  7.  
  8.     for (let i = 1; i <= num; i++) {
  9.       console.log(`${res}`);
  10.     }
  11.   }
Advertisement
Add Comment
Please, Sign In to add comment