I am with a JSON
object of a form, so I converted it normally and created a map
with only the names of users within a array
. The next step I need to do is parse all the names and get the one (s) that has the highest length
.
I've tried to use filter
and reduce
, but it always gives some kind of error, could someone tell me which algorithm to use?
Const nomes =["Luan","Pedro","Caio", "Mariana", "Lígia", "Rafaela"]
The result must be an array with the name (s) of the highest% of%.