Computer Science, asked by shiprasoni9, 3 months ago

wap to accept a string from user and print its lenghth​

Answers

Answered by bhattkashish1234
0

Answer:

public class print

{

public static void main ()

{

Scanner sc = new Scanner (System.in);

system.out.println("Enter a string");

String s= sc.nextLine();

System.out.println("The length of the string is "+ s.length())

}

}

Explanation:

please mark as a brainlist please

Similar questions