diff --git a/pset1.js b/pset1.js index da1c583..2bfd7d8 100644 --- a/pset1.js +++ b/pset1.js @@ -6,6 +6,10 @@ that stores your full name as a variable */ + + +let myFullName = 'Mielyn Acosta' + // ------------------------------------------- @@ -16,6 +20,11 @@ */ + + + let myHeight = 64; + + // ------------------------------------------- /* P3: @@ -24,6 +33,10 @@ */ + +let myBirthYear = 1988; + + // ------------------------------------------- /* P4: @@ -32,6 +45,10 @@ */ + +let currentYear = 2018; + + // ------------------------------------------- /* P5: @@ -41,6 +58,11 @@ */ + +let myAge = currentYear - myBirthYear; + + + // ------------------------------------------- /* P6: @@ -54,6 +76,11 @@ */ + +let myDescription = "Hello, my name is " + myFullName + " and I am " + myAge + " years old." + + "my height is" + myHeight + "inches." + " We are in the year of " + currentYear. + + console.log(myDescription); // ------------------------------------------- diff --git a/pset2.js b/pset2.js index 98d7b32..69c6dc4 100644 --- a/pset2.js +++ b/pset2.js @@ -3,24 +3,32 @@ // pleae create: // a variable called `helloWrold`, you can set it equal to whatever you want - +let helloWorld = 'Hello Mielyn' ; +console.log(helloWorld); // a variable called `this_is_snake_cased`, you can set it equal to whatever you want - +let this_is_snake_cased = 'MielynAcostaJoiningPuruit' ; +console.log(this_is_snake_cased); // a variable called `thisVarHasNumbers111`, you can set it equal to whatever you want - - +let thisVarHasNumbers111 = 2018; +console.log(thisVarHasNumbers111); // 1. create a string - it should be your first name - +let myString = 'Mielyn '; +console.log("My First name is " + myString); // 2. create another string - it should be your last name - - +let myString2 = 'Acosta'; +console.log("My last name is: " + myString2); // 3. create a third string using the first two strings you've defined // it should read [FIRST NAME][SPACE][LAST NAME] - +let myString3 = myString + ' ' + myString2; +console.log("My Full Name is: " + myString3); // 4. create a string - it should be your middle name - +let myString4 = 'De Lara'; +console.log("My Middle name is " + myString4); // 5. redefine the string in step 3. so that it now shows // [FIRST NAME][SPACE][MIDDLE NAME][SPACE][LAST NAME] + +let myString5 = myString + ' ' + myString4 + ' ' + myString2; +console.log("My Full name with middle name is: " + myString5);