Skip to content

Instantly share code, notes, and snippets.

View sethpuckett's full-sized avatar

Seth Puckett sethpuckett

View GitHub Profile
@sethpuckett
sethpuckett / bloc-assessment.md
Last active July 10, 2018 22:51
Bloc Full Stack Mentor Assessment

Javascript

Hey, Student! Your solution looks good. You've almost got it. One of the frustrating things about writing software is that you can be 99% there... and one bug breaks the whole thing!

Here's a tip that might help you here and with similar issues in the future.

When debugging, it's useful to experiment by isolating variables and testing with simpler scenarios. Try replacing alert(prizes[btnNum]); with alert(prizes[0]);. This isn't the functionality we want in the end, but simplifying the logic will tell us if there's a problem with the btnNum variable or with the alert array itself.

You should see that with prizes[0] the alert box displays A Unicorn! just as expected! This is a big clue. It means the problem must be with btnNum.

@sethpuckett
sethpuckett / keybase.md
Created June 1, 2017 00:37
Keybase Proof

Keybase proof

I hereby claim:

  • I am sethpuckett on github.
  • I am sethpuckett (https://keybase.io/sethpuckett) on keybase.
  • I have a public key ASBgulqUJvROf3465IkrJM6Zn3mdIx0pODg61hFvRtPCzgo

To claim this, I am signing this object: