Skip to content

Instantly share code, notes, and snippets.

View risico's full-sized avatar
💥
compiling

Robert Zimtea risico

💥
compiling
View GitHub Profile
@risico
risico / gist:9599215
Created March 17, 2014 13:29
sublime3
{
"always_prompt_for_file_reload": false,
"always_show_minimap_viewport": false,
"animation_enabled": true,
"atomic_save": true,
"auto_close_tags": true,
"auto_complete": true,
"auto_complete_commit_on_tab": false,
"auto_complete_delay": 50,
"auto_complete_selector": "source - comment, meta.tag - punctuation.definition.tag.begin",
"xxxxxxxx-xxxx-xxxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, function(e) {
var t = 16 * Math.random() | 0, n = "x" == e ? t : 3 & t | 8;
return n.toString(16)
})
### Keybase proof
I hereby claim:
* I am risico on github.
* I am risico (https://keybase.io/risico) on keybase.
* I have a public key whose fingerprint is A416 F294 DEF3 BD6A 9E32 F5B3 5FF5 8FEB E72E 2996
To claim this, I am signing this object:
$(window).scroll(function(){
var defaultView = document.defaultView.scrollMaxY;
var pageOffset = window.pageYOffset;
var tolerance = defaultView - 800;
if(pageOffset > tolerance){
$('#more').click();
}
});
#menu li {
float: left;
margin: 4px;
width: 100px;
}
#menu li.level1 ul {
display: none;
}
function countdown (num) {
for (var i = 0; i <= num; num--) {
alert(num);
}
}
countdown(5);
<ul id="menu">
<li class="level1">
Thing 1
<ul>
<li>Subthing A</li>
<li>Subthing B</li>
<li>Subthing C</li>
</ul>
</li>
<li class="level1">
U0 ArcExpandBuf(ArcCs *c)
//Use ExpandBuf() unless you know what
//you're doing.
{
U8 *dst_ptr,*dst_limit;
U64 basecode,lastcode,code;
ArcTableEntry *temp,*temp1;
dst_ptr=c->dst_buf+c->dst_pos;
dst_limit=c->dst_buf+c->dst_size;
@risico
risico / sort1mb.cpp
Created October 28, 2012 14:10 — forked from preshing/sort1mb.cpp
Sort one million 8-digit numbers in 1MB RAM
#include <stdio.h>
#include <stdlib.h>
#include <assert.h>
typedef unsigned int u32;
typedef unsigned long long u64;
//-------------------------------------------------------------------------
// WorkArea
//-------------------------------------------------------------------------
<!DOCTYPE html>
<html>
<head>
<meta charset=utf-8 />
<title>JS Bin</title>
</head>
<body>
</body>
</html>