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
#nprogress { | |
pointer-events: none | |
} | |
#nprogress .bar { | |
background: #a68735; | |
position: fixed; | |
z-index: 100; | |
top: 0; | |
left: 0; |
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
class Tiger | |
def initialize | |
@eyes = Eye.new(2) | |
end | |
def eye | |
@eyes.count > 1 ? 1 : 0 | |
end | |
end |
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
var good = "Lets see if this shit really does work."; | |
alert(good); |
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
class MinesweeperMap | |
def initialize(difficulty) | |
@difficulty = difficulty | |
case difficulty | |
when 1 | |
grid_size = 4 | |
when 2 | |
grid_size = 7 | |
when 3 |
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
Bonus: subsets | |
Attempt this after you have the other two problems working. | |
Write a method that, given an array of unique items, finds all the subsets of items: | |
subsets(["a", "b", "c"]) == [ | |
[], # note that the empty set counts! | |
["a"], ["a", "b"], ["a", "b", "c"], ["a", "c"] | |
["b"], ["b", "c"], |