I have a String s = java; What is the output when I say
s.replaceAll('j', 'k'); Also what is the value of s after
replacing?

Answer Posted / malli

Compile time error error.
String s=java here double quotes missing
and s.replaceAll('j','k'); here also we have to give double quotes.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

what are Hostile Applets?

1596


Can a class have more than one object?

518


What is qms certification?

513


Explain 5 io best practices?

587


How can you handle java exceptions?

517






What are the differences between processes and threads?

506


What are the loops in java?

515


What are data types in programming?

544


Is minecraft 1.15 out?

543


Is char a data type in java?

535


Name few "optional" classes introduced with java 8 ?

639


Explain purpose of sleep() method in java?

610


What must a class do to implement an interface in java programming?

529


How do you identify independent and dependent variables?

498


What is the full name of java?

559