This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width"> | |
<title>JS Bin</title> | |
</head> | |
<body> | |
<!-- Calendly badge widget begin --> | |
<link href="https://assets.calendly.com/assets/external/widget.css" rel="stylesheet"> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Iterative versions of https://gist.github.com/tparveen/edddf988ec68ef6bb74cff9d1284d09d | |
//Exercise 1 - Counting Sheep | |
//Write an iterative algorithm that counts how many sheep jumps over the fence. Your program should take a number | |
//as an input. That number should be the number of sheep you have. The program should diplay the number along | |
//with the msg "Another sheep jumps over the fence" until no more sheep left. | |
function countSheepLoop(num){ | |
for(let i=num; i>0; i--){ | |
console.log(`counting sheeps ${i}`); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//For each one these exercises identify the Big O. Once you have done so, put a counter | |
//variable and now check to see how the counter related to understanding the Big O for | |
//each of these algorithms. | |
/*================================================================================= | |
/* | |
Your task is to step through the code thoughly with | |
the input provided. You should be able to describe what is happening in each step. | |
Identify the Big O of this algorithm and be able to explain your answer. | |
Finally use a counter to show how your the counter can be helpful in understanding the |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Drill #1: | |
function isEven(value){ | |
if (value % 2 == 0){ | |
return true; | |
} | |
else | |
return false; | |
} | |
// O(1) Constant, because it was arithmetic |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Drill #1: | |
https://glitch.com/edit/#!/descriptive-fragrance | |
Drill #2: | |
https://glitch.com/edit/#!/boulder-bathroom |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Drill #1: | |
https://powerful-fir.glitch.me | |
Drill #2: | |
https://glitch.com/edit/#!/young-geese |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Drill #1: https://glitch.com/edit/#!/tough-argument?path=src/components/surprise-button.js:5:44 | |
Drill #2: https://glitch.com/edit/#!/cliff-park?path=src/components/rate-calculator.js:38:18 | |
Drill #3: https://glitch.com/edit/#!/bumpy-writer?path=src/components/live-search.js:28:11 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Drill #1: https://healthy-pantry.glitch.me | |
Drill #2: https://probable-scallion.glitch.me |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Traffic lights: | |
https://jsbin.com/veyuduw/edit?js,console,output | |
Error: https://jsbin.com/cozivu/edit?js,output |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Area: | |
https://jsbin.com/dudati/edit?html,js,console,output | |
Temp: | |
https://jsbin.com/giwoduw/edit?html,js,console,output | |
Divisible: | |
https://jsbin.com/kigula/edit?html,js,console,output |
NewerOlder