Question: In Java Please: Strings String stri - My name is Billy. String str2 My name is Billy-i How do you compare the strings above in

In Java Please:

In Java Please: Strings String stri - "My name is Billy." String

Strings String stri - "My name is Billy." String str2 "My name is Billy-"i How do you compare the strings above in an "if statement, checking only to see if the strings Question have the same characters? Choice 1 Choice 2 Choice3 Choice 4 Choice 5 if ( str1 str2 ) iE strl.compareTo str2 if str1.equals str2)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!