Intellipaat Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in Java by (5.3k points)

I have two string s, str1 and str2 How do I check if str2 is contained within str1, ignoring case

1 Answer

0 votes
by (9.5k points)

i think you should use

str1.toLowerCase().contains(str2.toLowerCase())

Related questions

0 votes
2 answers
asked Nov 25, 2019 in Java by Anvi (10.2k points)

31k questions

32.8k answers

501 comments

693 users

Browse Categories

...