0

What are strings in javascript?

7th Mar 2017, 10:17 AM
Gaurav Jaiswar
Gaurav Jaiswar - avatar
2 Answers
+ 6
JavaScript strings are used for storing and manipulating text. A JavaScript string simply stores a series of characters like "John Doe". A string can be any text inside quotes. You can use single or double quotes: var carname = "Volvo XC60"; var carname = 'Volvo XC60'; To learn about string methods, visit this link: https://www.w3schools.com/js/js_string_methods.asp
7th Mar 2017, 10:26 AM
Chirag Bhansali
Chirag Bhansali - avatar
+ 2
Strings are a group of character or we can say it is a sentence. characters are enclosed within single quotes like 'Char' but stritgs are enclosed within double quotes "String". May you have understood.
12th Jun 2017, 5:29 PM
Paavan Gupta
Paavan Gupta - avatar