Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nicole Valentini #214

Open
wants to merge 11 commits into
base: main
Choose a base branch
from
Open
55 changes: 35 additions & 20 deletions finalPrep/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,18 @@
Congrats on making it to the Mod 0 Final Prep! Complete the final exercises below and be sure to carefully follow the Pull Request steps to submit your work!

### Final Technical Prep
You've learned a ton about some of the core foundations of Javascript! Show us how far you've come by completing the following exercises! You will be using your work from these exercises in your first day of Mod 1!
You've learned a ton about some of the core foundations of Javascript! Show us how far you've come by completing the following exercises! You will be using your work from these exercises in your first day of Mod 1!

<<<<<<< HEAD
- [ ] Complete the [Mod Zero Hero Challenge](./modZeroHero.js)
- [ ] Complete the [Annotation Challenge](./annotations.js)
- [ ] Complete the [Annotation Challenge](./annotations.js)
=======
- [x] Complete the [Mod Zero Hero Challenge](./modZeroHero.js)
- [x] Complete the [Annotation Challenge](./annotations.js)
>>>>>>> 261a97b100131e528dc4a398cdf8439807feb83d

### Refactor Previous Work
You've learned A LOT over the last few weeks as it relates to technical content - chances are, you probably have some code from your previous exercises that is either sloppy, incorrect, poorly named, etc. Before starting Mod 1, we want you to `refactor` your code - which is the process of adjusting or improving your code for readability and accuracy.
You've learned A LOT over the last few weeks as it relates to technical content - chances are, you probably have some code from your previous exercises that is either sloppy, incorrect, poorly named, etc. Before starting Mod 1, we want you to `refactor` your code - which is the process of adjusting or improving your code for readability and accuracy.

Some things to consider as you refactor include...
- Are my variable names easy to understand/convey the data type they are assigned to?
Expand All @@ -18,38 +23,49 @@ Some things to consider as you refactor include...

Take your time as you go back and refactor your exercises from each section. We've included a handy checklist for you to go through below.

- [ ] I have refactored my `section1` exercises to the best of my ability
- [ ] I have refactored my `section2` exercises to the best of my ability
- [ ] I have refactored my `section3` exercises to the best of my ability
- [ ] I have refactored my `section4` exercises to the best of my ability
- [x] I have refactored my `section1` exercises to the best of my ability
- [x] I have refactored my `section2` exercises to the best of my ability
- [x] I have refactored my `section3` exercises to the best of my ability
- [x] I have refactored my `section4` exercises to the best of my ability

### Time Management Prep
In Mod 0 you've learned about different techniques for managing your time at Turing. Please create a calendar for your **first 3 weeks of Mod 1**. Feel free to make your calendar fit your style, but we suggest that your calendar should include the following:
- [ ] Standard M1 class schedule (see M1 calendar [here](https://frontend.turing.io/today/))
- [ ] Study/Project work time
- [ ] Health + Wellness
- [x] Standard M1 class schedule (see M1 calendar [here](https://frontend.turing.io/today/))
- [x] Study/Project work time
- [x] Health + Wellness

When you are finished, add screenshots of your calendar so we can provide feedback if needed!

- `Add Week 1 Screenshot Here`
- `Add Week 2 Screenshot Here`
- `Add Week 3 Screenshot Here`

- `Add Week 1 Screenshot Here` <img width="1083" alt="Screen Shot 2021-11-13 at 1 16 48 PM" src="https://user-images.githubusercontent.com/92831895/141657958-4656fa06-7a4c-4235-9f66-5a1f310bc22c.png">-
- `Add Week 2 Screenshot Here` <img width="1075" alt="Screen Shot 2021-11-13 at 1 17 27 PM" src="https://user-images.githubusercontent.com/92831895/141657982-f69397f6-0f54-43c3-bfd3-6c7b3356e407.png">
- - `Add Week 3 Screenshot Here` <img width="1083" alt="Screen Shot 2021-11-13 at 1 20 08 PM" src="https://user-images.githubusercontent.com/92831895/141657987-b709904c-e6ce-430e-b92b-9e3c2c241de2.png">
-
### Mentorship Prep
Mentorship is an integral part of the Turing experience and will help jumpstart your technical career. In order to get your mentor relationship started on the right foot, please complete the following deliverables:
<<<<<<< HEAD
- [ ] Complete the [Mentorship DTR Prep](https://gist.github.com/ericweissman/51965bdcbf42970d43d817818bfaef3c)
- [ ] Add link to your gist here:
- [ ] Add link to your gist here:

=======
- [x] Complete the [Mentorship DTR Prep](https://gist.github.com/ericweissman/51965bdcbf42970d43d817818bfaef3c)
- [x] Add link to your gist here: [My Gist](https://gist.github.com/nvalentini21/82164a69eeddd638e21287d951de7c5e)
>>>>>>> 261a97b100131e528dc4a398cdf8439807feb83d
### Lesson Prep
You've learned a lot about how to take strong notes during Mod 0. Show us your skills while you learn how to pre-teach content for your first lesson in Mod 1!
- [ ] Complete the [Pre Teaching Practice exercise](https://gist.github.com/ericweissman/0036e8fe272c02bd6d4bb14f42fd2f79) gist
- [ ] Add a link to your gist here:

- [x] Complete the [Pre Teaching Practice exercise](https://gist.github.com/ericweissman/0036e8fe272c02bd6d4bb14f42fd2f79) gist
- [x] Add a link to your gist here: [My gist](https://gist.github.com/nvalentini21/5a1df07d2c943c12dc6388edc615ae61)
### Group Work Prep
As part of Turing's project-based learning approach, you will often be working in pairs or larger groups. In order to set yourself (and your team) up for success, it is important to ensure you are prepared to be an equitable contributor and teammate.
<<<<<<< HEAD
- [ ] Complete the [DTR Guiding Questions](https://gist.github.com/ericweissman/c56f3a98cdce761808c21d498a52f5c6)
- [ ] Add a link to your gist here:
- [ ] Add a link to your gist here:

=======
- [x] Complete the [DTR Guiding Questions](https://gist.github.com/ericweissman/c56f3a98cdce761808c21d498a52f5c6)
- [x] Add a link to your gist here: [My gist](https://gist.github.com/nvalentini21/2b06194bae7d8db96962e240ae80a2a3)

>>>>>>> 261a97b100131e528dc4a398cdf8439807feb83d
## All Done? How to Submit your M1 Prework
When you have completed *ALL* the activities described above, follow the steps below to submit your technical prework.

Expand Down Expand Up @@ -87,4 +103,3 @@ What is your plan and how are you going to hold yourself to it? Specifically...

## Extensions
Check out our thoughts on [extension activities](https://mod0.turing.io/prework/extensions) if you find yourself with some extra time before starting Mod 1!

33 changes: 29 additions & 4 deletions finalPrep/annotations.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,41 +2,66 @@
// Use the double // to create a new comment

//Build a Bear
//Declare a function named buildABear with parameters name, age, fur, clothes, special power.
function buildABear(name, age, fur, clothes, specialPower) {
//assign variable greeting to the string. Interpolate undefined name parameter into the string.
var greeting = `Hey partner! My name is ${name} - will you be my friend?!`;
//assign variable 'demographics' to an array with the paramenters name, age.
var demographics = [name, age];
//assign variable 'powerSaying' to the string with concatenated special power.
var powerSaying = "Did you know that I can " + specialPower + " ?";
// assign variable builtbear to an object with the keyvalue pairs
var builtBear = {
//assign key 'basicInfo' to value 'demographics'
basicInfo: demographics,
//set key 'clothes' to the value 'clothes'
clothes: clothes,
//set key 'exterior' to the value 'fur'
exterior: fur,
//set key cost to the value 49.99
cost: 49.99,
//set key saying to the value array '[greeting, powerSaying, "Goodnight my friend!"]
sayings: [greeting, powerSaying, "Goodnight my friend!"],
//set key isCuddly to the boolean value of true.
isCuddly: true,
};

//return the value of builtBear to the function caller.
return builtBear
}

//call the buildaBear function and assign the arguments below to the parameters.
buildABear('Fluffy', 4, 'brown', ['pants', 'jorts', 'tanktop'], 'give you nightmares');
//call the buildaBear function and assign the arguments below to the parameters.
buildABear('Sleepy', 2, 'purple', ['pajamas', 'sleeping cap'], 'sleeping in');



//FizzBuzz
//Declare a function called fizzBuzz with parameters num1, num2, range.
function fizzBuzz(num1, num2, range) {
//Initialize loop at 0, with an end point of less than or equal to the range parameter,
//increase by an increment of 1.
for (var i = 0; i <= range; i++) {
//set the condition: if the remainder of i into num1 is strictly equal to zero AND
// the remainder of i into num 2 is strictly equal to zero,
if (i % num1 === 0 && i % num2 === 0) {
//Then log to the console the string 'fizzbuzz'
console.log('fizzbuzz');
//If the remainder of i into num1 is strictly equal to 0
} else if (i % num1 === 0) {
//Log to the console the string "fizz"
console.log('fizz');
//If the remainder of i into num2 is strictly equal to 0
} else if (i % num2 === 0) {
//Log to the console "buzz."
console.log('buzz');
//If none of hte above conditions are true, then log i to the console.
} else {
console.log(i);
}
}
}

//call the function fizzBuzz with the arguments 3, 5, 100 assigned.
fizzBuzz(3, 5, 100);
fizzbuzz(5, 8, 400);

//call the function fizzBuzz with the arugments 5, 8, 400 assigned.
fizzbuzz(5, 8, 400);
104 changes: 92 additions & 12 deletions finalPrep/modZeroHero.js
Original file line number Diff line number Diff line change
@@ -1,52 +1,84 @@
// Challenge - See if you can follow the instructions and complete the exercise in under 30 minutes!

// Declare two variables - heroName AND specialAbility - set to strings

var heroName = "Superman";
var specialAbility = "laser vision";
// Declare two variables - greeting AND catchphrase
// greeting should be assigned to a string that uses concatenation to include the heroName
// catchphrase should be assigned to a string that uses interpolation to include the specialAbility

var greeting = "Hello friend!";
var catchphrase = "Saving the world is my specialty";
console.log (greeting + " My name is " + heroName);
console.log (`${catchphrase} and so is ${specialAbility}`);
// Declare two variables - power AND energy - set to integers
var power = 20
var energy = 150

// Declare two variables - fullPower AND fullEnergy
// fullPower should multiply your current power by 500
// fullEnergy should add 150 to your current energy

var fullPower = power * 500
var fullEnergy = energy + 150
console.log(fullPower);
console.log(fullEnergy);
// Declare two variables - isHuman and identityConcealed - assigned to booleans

var isHuman = true
var identityConcealed = true

// Declare two variables - archEnemies AND sidekicks
// archEnemies should be an array of at least 3 different enemy strings
// sidekicks should be an array of at least 3 different sidekick strings

var archEnemies = ["Magneto", "Penguin", "Bane"]
var sideKicks = ["Robin", "Tinkerbell", "ScoobyDoo"]
// Print the first sidekick to your console
console.log(sideKicks[0]);

// Print the last archEnemy to the console

console.log(archEnemies[2])
// Write some code to add a new archEnemy to the archEnemies array

archEnemies.push("Plankton");
// Print the archEnemies array to console to ensure you added a new archEnemy

console.log(archEnemies);
// Remove the first sidekick from the sidekicks array
sideKicks.shift();

// Print the sidekicks array to console to ensure you added a new sidekick
console.log(sideKicks);

// Create a function called assessSituation that takes three arguments - dangerLevel, saveTheDay, badExcuse
// - dangerLevel should be an integer
// - saveTheDay should be a string a hero would say once they save the day
// - saveTheDay should be a string a hero would say once they save the day
// - badExcuse should be a string a hero would say if they are too afraid of the dangerLevel

// Your function should include an if/else statement that meets the following criteria
// - Danger levels that are above 50 are too scary for your hero. Any danger level that is above 50 should result in printing the badExcuse to the console
// - Anything dangerLevel that is between 10 and 50 should result in printing the saveTheDay string to the console
// - If the dangerLevel is below 10, it means it is not worth your time and should result in printing the string "Meh. Hard pass." to the console.

function assessSituation(dangerLevel, saveTheDay, badExcuse) {
if (dangerLevel >= 50) {
console.log(badExcuse);
}
else if ((dangerLevel < 50) && (dangerLevel >= 10)){
console.log(saveTheDay);
}
else {
console.log("It's all good fam.");
}
};
var saveTheDay = "It's my duty."
var badExcuse = "Meh, hard pass."
assessSituation(25, saveTheDay, badExcuse);

//Test Cases
var announcement = 'Never fear, the Courageous Curly Bracket is here!';
var excuse = 'I think I forgot to lock up my 1992 Toyota Coralla. Be right back.';
// assessSituation(99, announcement, excuse) > Should print - 'I think I forgot to lock up my 1992 Toyota Coralla. Be right back.'
//assessSituation(21, announcement, excuse) > should print - 'Never fear, the Courageous Curly Bracket is here!'
//assessSituation(3, announcement, excuse) > should print - "Meh. Hard pass."
assessSituation (99, announcement, excuse);
assessSituation (21, announcement, excuse);
assessSituation (3, announcement, excuse);

// Declare a new variable - scaryMonster - assigned to an Object with the following key/values
// - name (string)
Expand All @@ -55,17 +87,57 @@ var excuse = 'I think I forgot to lock up my 1992 Toyota Coralla. Be right back.
// - citiesDestroyed (array)
// - luckyNumbers (array)
// - address (object with following key/values: number , street , state, zip)
var scaryMonster = {
name: "Godzilla",
smell: "seaweed",
weight: 20000,
citiesDestroyed: ["Tokyo", "New York", "Paris"],
luckyNumbers: [2, 45, 54, 68],
address: address = {
number: 2828,
street: "Zuni",
state: "Colorado",
zip: 80211
}
}
console.log(scaryMonster);


// Create a new class called SuperHero
// - Your class should have the following DYNAMIC values
// - name
// - name
// - superpower
// - age
// - age
// - Your class should have the following STATIC values
// - archNemesis, assigned to "The Syntax Error"
// - powerLevel = 100
// - energyLevel = 50
// - energyLevel = 50
class SuperHero {
constructor(name, superpower, age) {
this.name = name;
this.superpower = superpower;
this.age = age;
this.archNemesis = "The Syntax Error";
this.powerLevel = 1000;
this.energyLevel = 50;
}
sayName() {
console.log(this.name);
}
maximizeEnergy() {
this.energyLevel = 1000
}
gainPower(number) {
this.powerLevel = number * this.powerLevel
}
};

var superHero1 = new SuperHero("SpiderMan", "Web-spinning", 25);
var superHero2 = new SuperHero("Wonder Woman", "Strength", 29);


superHero1.gainPower(2);
console.log(superHero1);

// - Create the following class methods
// - sayName, should print the hero's name to the console
Expand All @@ -77,8 +149,16 @@ var excuse = 'I think I forgot to lock up my 1992 Toyota Coralla. Be right back.

// Reflection
// What parts were most difficult about this exerise?
//I had difficulty with if statements, particularly getting the syntax right. I also had trouble
//with declaring a function, again due to small syntax mistakes.

// What parts felt most comfortable to you?
//I felt comfortable declaring variables, creating an object, and creating a class.

// What skills do you need to continue to practice before starting Mod 1?
//I definitely need to practice over and over writing diffferent types of functions,
//if statements, and creating classes. Most of the issues I've had is not remembering the
//correct syntax, and making small errors that cost me a lot of time.

//Update 11.16.21 - Somehow my ModZero hero did not get pushed over to github, so going to repush it now
//as per feedback from Cydnee.
16 changes: 11 additions & 5 deletions section1/exercises/concatenation.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,17 @@ var creatures = "unicorns";
console.log("My zoo has " + numberOfCreatures + " " + creatures + "!")

// YOU DO: What data type will be logged to the console as a result of line 22? Explain.
// Your answer and explanation here:

// Your answer and explanation here:
"My zoo has 7 unicorns!"
//This will be logged as a string because it is enclosed in quotations.

// YOU DO:
// Write code that combines the variables below into a string that
// reads "The quick red fox jumped over the lazy brown dog":
var speedy = "quick red fox";
var slowPoke = "lazy brown dog";

console.log("The " + speedy + " jumped over the " + slowPoke)

// YOU DO:
// Write code that combines the variables below into a string that
Expand All @@ -42,14 +44,18 @@ speedy = "hare";


// YOU DO:
// Declare three variables, name/content/data type of your choice. Think carefully about what
// Declare three variables, name/content/data type of your choice. Think carefully about what
// you name the variables. Remember, the goal is to be concise but descriptive (it's a hard balance!)
// Then, log out ONE sentence that incorporates all THREE variables.
var dog = "Border Collie"
var description = "fastest dog in the world"
age = 15

console.log( "The " + dog + " is the " + description + " and can live to be " + age " years old.")

//-------------------
// FINAL CHECK
//-------------------

// Did you run this file in your terminal to make sure everything printed out to the console
// as you would expect? You should be doing this by now, and getting into the habit of it.
// Did you run this file in your terminal to make sure everything printed out to the console
// as you would expect? You should be doing this by now, and getting into the habit of it.
Loading