Javascript String Quiz
Javascript examples for String:Quiz
HOME
Javascript
String
Quiz
Description
Click the following links for the tutorial for String and Quiz.
Assign the string "Hello World!" to the variable txt.
Use the length property to display the length of a string variable's value.
Use escape characters to display the text correctly.
Concatenate the two strings to display "Hello World!".
Display the position of the first occurrence of "World" in the variable txt.
Use the slice() method to get substring
Use the replace() method to replace "World" with "Universe".
Convert the value of string to upper case.
Convert the value of txt to lower case.
Use the concat() method to join the two strings: str1 and str2.