DekGenius.com
Home
(current)
Dictionary
BOOKS
LYRICS
CHORD
SCRIPT & CODE EXAMPLE
Karaoke language
Search
Go
SCRIPT & CODE EXAMPLE
CODE EXAMPLE FOR JAVASCRIPT
how to find the longest string in given string using js
function longestWordLength(str) { return Math.max(...str.split(' ').map(word => word.length)); }
Source by www.samanthaming.com #
PREVIOUS
NEXT
Tagged:
#find
#longest
#string
#string
#js
ADD COMMENT
Topic
COMMENT
Name
6+7 =
Submit