Write a JavaScript function which can take any number of
strings as arguments and outputs them as a single
concatenated string.
Answer Posted / madhav arora
Lets Declare two variables :"a" and "b" to solve this
problem :
var a = 'Hello world!';
var b = 'I am a JavaScript hacker.'
First of all, you can concatenate strings, sew them
together as it were:
document.write(a + b);
gives
Hello world!I am a JavaScript hacker
| Is This Answer Correct ? | 4 Yes | 5 No |
Post New Answer View All Answers
What is JavaScript?
Explain javascript event delegation model?
What are the distinct types of error name values?
Consider the following code: 1 2 3 4 5 (function() { var a = b = 5; })(); console.log(b); what will be printed on the console?
Does spacing matter in javascript?
What is scope javascript?
What output will this program produce System.out.println(x+"+"+y+"="+(x+));
How do you change the style/class on any element using javascript?
Where are cookies actually stored on the hard disk?
why we calld java object orinted programming language??
What is difference between arrow function and normal function?
Where do you write javascript?
How does typeof operator work?
How do I install javascript?
What is console.time() and console.timeend()? What is its syntax, and why is it used?