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 MinHeap { | |
constructor () { | |
/* Initialing the array heap and adding a dummy element at index 0 */ | |
this.heap = [null] | |
} | |
getMin () { | |
/* Accessing the min element at index 1 in the heap array */ | |
return this.heap[1] | |
} |
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
export const safeColors = [ | |
"FFFFCC", | |
"FFFF99", | |
"FFFF66", | |
"FFFF33", | |
"FFFF00", | |
"CCCC00", | |
"FFCC66", | |
"FFCC00", | |
"FFCC33", |
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
<div id="lamp"> | |
<input type="radio" name="switch" value="on" /> | |
<input type="radio" name="switch" value="off" checked="checked"/> | |
<label for="switch" class="entypo-lamp"></label> | |
<div class="lamp"> | |
<div class="gonna-give-light"></div> | |
</div> | |
</div> |