Course contentsShow
JavaScript
Lesson 167 of 2,7235. StringsPro lesson

Common Pitfalls with indexOf() and -1

Avoid bugs by properly checking for -1 when a substring is not found with indexOf().

This lesson is for subscribers

You've completed the free preview. Subscribe to unlock every lesson in every course.