From 3b8a1fc90678a7c8465fc23add420bd0a02ef7a2 Mon Sep 17 00:00:00 2001 From: Daniel Autrey Date: Mon, 22 Jan 2018 15:15:15 -0500 Subject: [PATCH] My first commit --- starter-code/basic-algorithms.js | 24 +++++++++++++++++------- 1 file changed, 17 insertions(+), 7 deletions(-) diff --git a/starter-code/basic-algorithms.js b/starter-code/basic-algorithms.js index 82f20d8ba..da1d85d8a 100644 --- a/starter-code/basic-algorithms.js +++ b/starter-code/basic-algorithms.js @@ -1,7 +1,17 @@ -// Names and Input - - -//Conditionals - - -// Lorem ipsum generator +var hacker1 = "Danny" +var hacker2 = prompt("what is your name?") +console.log("The drivers name is " + hacker1) +console.log("The navigator's name is " + hacker2) +if (hacker1.length > hacker2.length){ + console.log("The Driver has the longest name, it has XX characters"); +} else if (hacker2.length > hacker1.length) { + console.log("Yo, navigator got the longest name, it has XX characters"); +} else { + console.log("wow, you both got equally long names, XX characters!!") +} +for(var i=0; i<1; i++){ + console.log(hacker1.split("").join(" ").toUpperCase()) +} +for(var i=0; i<1; i++){ + console.log(hacker2.split("").reverse) +} \ No newline at end of file pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy