I have 2 questions:
-
Suppose if i have a string
"Have a nice day"
this is the output I want:" "(15 spaces) -
Also how do you create a string dynamically in javascript
For eg: inruby"A"*10
"AAAAAAAAAA"
If the latter is possible I could have done the first one ( something like this. ) " "*(input.length)
Ans for Q1:
Ans for Q2: