Last active
October 25, 2024 09:02
-
-
Save anaclumos/8cb9c9caff35672038418afc3ec19a5e to your computer and use it in GitHub Desktop.
Silicon Valley S06 E04 Richard Hendricks Sorted List Brute Force Search Code
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(R. Hendricks 112) int index = 0; | |
(R. Hendricks 113) while (!element.equals(sortedList.get(index)) | |
(R. Hendricks 114) && sortedList.size() > ++index); | |
(R. Hendricks 115) return index < sortedList.size() ? index : -1; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
😂😂😂😂