Your browser lacks required capabilities. Please upgrade it or switch to another to continue.
Loading…
<<set $stepsTaken_Array to []>>
<<set $stepsNeeded_Array = ["rep(4Down){organize(books,E1);}"]>>\<<set _commandLength = $stepsTaken_Array.length>>\
<<if $step1Visited == null>>\
<<set $step1Visited = true>>\
[img[Images\Day20\GSDay20BG1.png]]
"Aha! Great to see you. I was just about to put away that book I borrowed, but I stumbled into a slight dilemma."
<<set _show to { start: 0, end: 2}>>\
<div class='hide' id='next0'>[img[Images\Day20\GSDay20BG2.png]]
"The books are on the shelves, but none of them are organized. It seems we will need to do one last step after all and organize the books on each shelf."</div>
<div class='hide' id='next1'>[img[Images\Day20\GSDay20BG3.png]]
"Let me teach you a new command. Try <span class='redBold'>rep (4Down) { organize(books, E1); }</span> "
<label>Enter a command. <<textbox "_commandString" "">></label>
[[Enter command.|Steps 1 - 6 Evaluation][$stepsTaken_Array.push(_commandString)]]</div>
<<else>>
[img[Images\Day20\GSDay20BG3.png]]
"Let me teach you a new command. Try <span class='redBold'>rep (4Down) { organize(books, E1); }</span> "
<label>Enter a command. <<textbox "_commandString" "">></label>
[[Enter command.|Steps 1 - 6 Evaluation][$stepsTaken_Array.push(_commandString)]]
<</if>>[img[Images\Day15\GSDay15BG36.png]]
"Phew. Thank you. I think I've calmed down a bit."
<<set _show to { start: 0, end: 4}>>\
<div class='hide' id='next0'>[img[Images\Day15\GSDay15BG37.png]]
"Why don't you help me carry these to the Library? Then we can head back to the Dorm."</div>
<div class='hide' id='next1'>[img[Images\Day15\GSDay15BG38.png]]
"Thank you for helping today. I'm sorry I got so mad earlier, I'm sure you kinda just got dragged into that mess."</div>
<div class='hide' id='next2'>[img[Images\Day15\GSDay15BG39.png]]
"Here's a treat to thank you. Hope you like ice cream!"</div>
<div class='hide' id='next3'>[img[Images\Day15\GSDay15BG40.png]]
"Oh... Oh no..."
----
Good job! This lesson's password is: <span class ='whiteBold'>Pearl</span>
Enter it in the Google Forms link!</div><<set _gotIt = true>>\
<<for _i to 0; _i < $stepsTaken_Array.length; _i ++>>\
<<set _gotIt = $stepsTaken_Array[_i].replace(/\s/g,'') == $stepsNeeded_Array[_i].replace(/\s/g,'')>>\
<<if _gotIt == false>>\
<<break>>
<</if>>\
<</for>>\
<<if _gotIt == false>>\
Looks like you had an error somewhere. Try it again.
[[Go back.|Steps 1 - 6][$stepsTaken_Array = []]]
<<else>>\
A strange power surges into your hand and you sort the entire column at once.
[[Wh-who-whoaaaaaaaaaa!|Steps 7 - 11]]
<<set $stepsNeeded_Array = []>>
<<set $stepsTaken_Array = []>>
<</if>>\<<set _commandLength = $stepsTaken_Array.length>>\
<<if $step7Visited == null>>\
<<set $step7Visited = true>>\
<<set $stepsNeeded_Array = ["rep(4Up){organize(books,A4);}"]>>\
[img[Images\Day20\GSDay20BG4.png]]
"Ta-da! Instead of doing each shelf individually, you can do all 4 shelves in one column this way."
<<set _show to { start: 0, end: 2}>>\
<div class='hide' id='next0'>"Like a normal repeat loop, you will specify the number in the ( ) and the code you want to run in the { } . Make sure to set the position to where you wish to start your loop."</div>
<div class='hide' id='next1'>[img[Images\Day20\GSDay20BG5.png]]
"You also need the <span class='whiteBold'>Direction</span> that you want your repeat loop to move in. Shall we try <span class='redBold'>rep (4Up) { organize(books, A4); }</span> to fill the shelves from the bottom-up this time?"
<label>Enter a command. <<textbox "_commandString" "">></label>
[[Enter command.|Steps 7 - 11 Evaluation][$stepsTaken_Array.push(_commandString)]]</div>
<<else>>
[img[Images\Day20\GSDay20BG5.png]]
"You also need the <span class='whiteBold'>Direction</span> that you want your repeat loop to move in. Shall we try <span class='redBold'>rep (4Up) { organize(books, A4); }</span> to fill the shelves from the bottom-up this time?"
<label>Enter a command. <<textbox "_commandString" "">></label>
[[Enter command.|Steps 7 - 11 Evaluation][$stepsTaken_Array.push(_commandString)]]
<</if>><<set _gotIt = true>>\
<<for _i to 0; _i < $stepsTaken_Array.length; _i ++>>\
<<set _gotIt = $stepsTaken_Array[_i].replace(/\s/g,'') == $stepsNeeded_Array[_i].replace(/\s/g,'')>>\
<<if _gotIt == false>>\
<<break>>
<</if>>\
<</for>>\
<<if _gotIt == false>>\
Looks like you had an error somewhere. Try it again.
[[Go back.|Steps 7 - 11][$stepsTaken_Array = []]]
<<else>>\
You sort the column cleanly.
[[Heh, I'm nice.|Steps 12 - 15]]
<<set $stepsNeeded_Array = []>>
<<set $stepsTaken_Array = []>>
<</if>>\<<set _commandLength = $stepsTaken_Array.length>>\
<<set $stepsNeeded_Array = ["rep(3Right){organize(books,B1);}"]>>\
<<if $step12Visited == null>>\
<<set $step12Visited = true>>\
[img[Images\Day20\GSDay20BG6.png]]
"Glorious. It appears you are starting to get the hang of it. "
<<set _show to { start: 0, end: 1}>>\
<div class='hide' id='next0'>[img[Images\Day20\GSDay20BG7.png]]
"Now, can you fill in shelves B1, C1, and D1 using a repeat loop that starts from shelf <span class='whiteBold'>B1</span>? Think of which <span class='whiteBold'>Direction</span> you need to move in, and <span class='whiteBold'>how many</span> shelves you need to organize."
<label>Enter a command. <<textbox "_commandString" "">></label>
[[Enter command.|Steps 12 - 15 Evaluation][$stepsTaken_Array.push(_commandString)]]</div>
<<else>>
[img[Images\Day20\GSDay20BG7.png]]
"Now, can you fill in shelves B1, C1, and D1 using a repeat loop that starts from shelf <span class='whiteBold'>B1</span>? Think of which <span class='whiteBold'>Direction</span> you need to move in, and <span class='whiteBold'>how many</span> shelves you need to organize."
<label>Enter a command. <<textbox "_commandString" "">></label>
[[Enter command.|Steps 12 - 15 Evaluation][$stepsTaken_Array.push(_commandString)]]
<</if>><<set _gotIt = true>>\
<<for _i to 0; _i < $stepsTaken_Array.length; _i ++>>\
<<set _gotIt = $stepsTaken_Array[_i].replace(/\s/g,'') == $stepsNeeded_Array[_i].replace(/\s/g,'')>>\
<<if _gotIt == false>>\
<<break>>
<</if>>\
<</for>>\
<<if _gotIt == false>>\
Looks like you had an error somewhere. Try it again.
[[Go back.|Steps 12 - 15][$stepsTaken_Array = []]]
<<else>>\
You run your hand across the targeted shelves and sort everything.
[[Heh. I've mastered this power.|Steps 16 - 17]]
<<set $stepsNeeded_Array = []>>
<<set $stepsTaken_Array = []>>
<</if>>\<<set _commandLength = $stepsTaken_Array.length>>\
<<set $stepsNeeded_Array = ["rep(3Left){organize(books,D2);}"]>>\
<<if $step16Visited == null>>\
<<set $step16Visited = true>>\
[img[Images\Day20\GSDay20BG8.png]]
"Stellar. Can you organize the books one row lower, but in the opposite direction?"
<label>Enter a command. <<textbox "_commandString" "">></label>
[[Enter command.|Steps 16 - 17 Evaluation][$stepsTaken_Array.push(_commandString)]]
<<else>>
[img[Images\Day20\GSDay20BG8.png]]
"Stellar. Can you organize the books one row lower, but in the opposite direction?"
<label>Enter a command. <<textbox "_commandString" "">></label>
[[Enter command.|Steps 16 - 17 Evaluation][$stepsTaken_Array.push(_commandString)]]
<</if>>
<<set _gotIt = true>>\
<<for _i to 0; _i < $stepsTaken_Array.length; _i ++>>\
<<set _gotIt = $stepsTaken_Array[_i].replace(/\s/g,'') == $stepsNeeded_Array[_i].replace(/\s/g,'')>>\
<<if _gotIt == false>>\
<<break>>
<</if>>\
<</for>>\
<<if _gotIt == false>>\
Looks like you had an error somewhere. Try it again.
[[Go back.|Steps 16 - 17][$stepsTaken_Array = []]]
<<else>>\
After flicking the first shelf, you sweep your hand to the left, sorting everything in a single go.
[[Power overwhelming! Hahaha!!!|Steps 18 - 21]]
<<set $stepsNeeded_Array = []>>
<<set $stepsTaken_Array = []>>
<</if>>\<<set _commandLength = $stepsTaken_Array.length>>\
<<set $stepsNeeded_Array = ["organize(books,B3);",
"organize(books,C4);","organize(books,D3);"]>>\
<<if $step18Visited == null>>\
<<set $step18Visited = true>>\
[img[Images\Day20\GSDay20BG9.png]]
Smashing. I think you are really starting to get a firm handle on this. Great job!"
<<set _show to { start: 0, end: 1}>>\
<div class='hide' id='next0'>[img[Images\Day20\GSDay20BG10.png]]
"Time to handle the last few shelves. This time, see if you recall how to fill in shelves individually. You can use 3 individual commands this time."
<label>Enter a command. <<textbox "_commandString" "">></label>
[[Enter command.|Steps 18 - 21][$stepsTaken_Array.push(_commandString)]]</div>
<<else>>
[img[Images\Day20\GSDay20BG10.png]]
"Time to handle the last few shelves. This time, see if you recall how to fill in shelves individually. You can use 3 individual commands this time."
<<if _commandLength < $stepsNeeded_Array.length>><label>Enter a command. <<textbox "_commandString" "">></label>
[[Enter command.|Steps 18 - 21][$stepsTaken_Array.push(_commandString)]]
[[Clear the commands.|Steps 18 - 21][$stepsTaken_Array = []]]
<</if>>\
<<if _commandLength >= $stepsNeeded_Array.length>>\
[[Check solution.|Steps 18 - 21 Evaluation]]
[[Clear the commands.|Steps 18 - 21][$stepsTaken_Array = []]]
<</if>>\
<</if>>
<<if _commandLength > 0>>\
Current commands:
<<for _i to 0; _i < _commandLength; _i ++>>\
<<if $stepsTaken_Array[_i] != "" && $stepsTaken_Array[_i] != " ">>\
<<print $stepsTaken_Array[_i]>>
<<else>>\
Blank Command
<</if>>\
<</for>>
<</if>><<set _gotIt = true>>\
<<for _i to 0; _i < $stepsTaken_Array.length; _i ++>>\
<<set _gotIt = $stepsTaken_Array[_i].replace(/\s/g,'') == $stepsNeeded_Array[_i].replace(/\s/g,'')>>\
<<if _gotIt == false>>\
<<break>>
<</if>>\
<</for>>\
<<if _gotIt == false>>\
Looks like you had an error somewhere. Try it again.
[[Go back.|Steps 18 - 21][$stepsTaken_Array = []]]
<<else>>\
A flick of the wrist, and the sort of the books.
[[Pretty cool, huh?|Steps 22 - 23]]
<<set $stepsNeeded_Array = []>>
<<set $stepsTaken_Array = []>>
<</if>>\<<set _commandLength = $stepsTaken_Array.length>>\
<<set $stepsNeeded_Array = ["organize(books,B4);",
"organize(books,C3);","organize(books,D4);"]>>\
<<if $step22Visited == null>>\
<<set $step22Visited = true>>\
[img[Images\Day20\GSDay20BG11.png]]
"Bravo! You realized that there was no need for a repeat loop! Shall we finish up with the final set?"
<label>Enter a command. <<textbox "_commandString" "">></label>
[[Enter command.|Steps 22 - 23][$stepsTaken_Array.push(_commandString)]]
<<else>>
[img[Images\Day20\GSDay20BG11.png]]
"Bravo! You realized that there was no need for a repeat loop! Shall we finish up with the final set?"
<<if _commandLength < $stepsNeeded_Array.length>><label>Enter a command. <<textbox "_commandString" "">></label>
[[Enter command.|Steps 22 - 23][$stepsTaken_Array.push(_commandString)]]
[[Clear the commands.|Steps 22 - 23][$stepsTaken_Array = []]]
<</if>>\
<<if _commandLength >= $stepsNeeded_Array.length>>\
[[Check solution.|Steps 22 - 23 Evaluation]]
[[Clear the commands.|Steps 22 - 23][$stepsTaken_Array = []]]
<</if>>\
<</if>>
<<if _commandLength > 0>>\
Current commands:
<<for _i to 0; _i < _commandLength; _i ++>>\
<<if $stepsTaken_Array[_i] != "" && $stepsTaken_Array[_i] != " ">>\
<<print $stepsTaken_Array[_i]>>
<<else>>\
Blank Command
<</if>>\
<</for>>
<</if>><<set _gotIt = true>>\
<<for _i to 0; _i < $stepsTaken_Array.length; _i ++>>\
<<set _gotIt = $stepsTaken_Array[_i].replace(/\s/g,'') == $stepsNeeded_Array[_i].replace(/\s/g,'')>>\
<<if _gotIt == false>>\
<<break>>
<</if>>\
<</for>>\
<<if _gotIt == false>>\
Looks like you had an error somewhere. Try it again.
[[Go back.|Steps 22 - 23][$stepsTaken_Array = []]]
<<else>>\
You smile and do another sort-sweep.
[[And that, as they say, is that.|Steps 24 - 29]]
<<set $stepsNeeded_Array = []>>
<<set $stepsTaken_Array = []>>
<</if>>\[img[Images\Day20\GSDay20BG12.png]]
"Heavenly. Look at this place. It is majestic. You really did an amazing job here, truly."
<<set _show to { start: 0, end: 3}>>\
<div class='hide' id='next0'>[img[Images\Day20\GSDay20BG13.png]]
"Look at that, I can plainly see where to return the borrowed book. Thank you again!"</div>
<div class='hide' id='next1'>"What? Why do I still have a tail? Oh, well I grew it out when we were trying to tame the animals the other day. I think I'll keep it."</div>
<div class='hide' id='next2'>"Now I should really go find that librarian so I can check out that next issue. Take care!"
----
Today's password: <span class = 'whiteBold'>Heliodor</span></div>