V.Vidhya Logo

V.Vidhya

String Basics


Q1.

Declare your name as a string and print its length in JS.


Q2.

Declare your first name as a string and print its first character.


Q3.

Declare your first name as string and print its last character.


Q4.

What will be the output of following code:

You have to predict the output yourself without running/executing the code.

console.log( "JavaScript" + 123 );

Q5.

What is the length of an empty string & a string with a single space?


Prev Post
Identifiers
Next Post
if-else (Conditional Statements)