javascript define string with length code example
Example 1: javascript string length
const s = 'Hello, World!';
console.log(s.length);
Example 2: javascript create string of given length
var str = new Array(len + 1).join( character );
const s = 'Hello, World!';
console.log(s.length);
var str = new Array(len + 1).join( character );