Q. Which method is used to check if a string contains a substring?

A
contains()
B
includes()
C
has()
D
match()
Solution:

The contains() method returns true if the string contains the specified substring.

Entri Contact Image

Get Expert Advice for Free: Register for Your Free Consultation Now!