Skip to content

Def-mex-pt2 Luis Felipe Martinez Guzman - #317

Closed
luisf89 wants to merge 1 commit into
ironhack-labs:masterfrom
luisf89:master
Closed

Def-mex-pt2 Luis Felipe Martinez Guzman#317
luisf89 wants to merge 1 commit into
ironhack-labs:masterfrom
luisf89:master

Conversation

@luisf89

@luisf89 luisf89 commented Jan 18, 2019

Copy link
Copy Markdown

No supe como hacer que despliege el mensaje cuando los nombres son iguales.

@ta-web-mex

Copy link
Copy Markdown
The Driver has the longest name, it has XX characters or
Yo, navigator got the longest name, it has XX characters or
wow, you both got equally long names, XX characters!!

Si te refieres a este caso? esta podria ser una buena solucion

if(Hacker1.length > Hacker2.length){
  console.log("the driver has the longest name it has "+ Hacker1.length + " characters");
  
} else if (Hacker2.length> Hacker1.length){
  console.log("the navigator has the longest name it has "+ Hacker2.length + " characters");
  
} else if(Hacker1.length == Hacker2.length){
  console.log("Wow you goth equally long names it has "+ Hacker2.length+ " characters");
}

Sigue entrenado para sacar el poder

@ta-web-mex ta-web-mex closed this Jan 22, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants