I hereby claim:
- I am scdf on github.
- I am scdf (https://keybase.io/scdf) on keybase.
- I have a public key ASAKl-URAtBD4HZHO_6e0zYOWs-qZ1wzdZfw64VZF7WibAo
To claim this, I am signing this object:
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Margin test</title> | |
</head> | |
<body> | |
<div id="one"> | |
<h1>Lorum ipsum</h1> | |
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p> | |
</div> |
% Benchmarking code for REPL nicked and modified to remove module param from here: | |
% https://erlangcentral.org/wiki/index.php/Measuring_Function_Execution_Time | |
% Params: FnName, Params, Rounds, eg: | |
% TC(DeepGet, [DeepGet, [<<"userCtx">>, <<"name">>], Req], 100000). | |
% TC = fun(TC_F, TC_A, TC_N) when TC_N > 0 -> TC_L = tl([begin {TC_T, _Result} = timer:tc(TC_F, TC_A), TC_T end || _ <- lists:seq(1, TC_N)]), TC_Min = lists:min(TC_L), TC_Max = lists:max(TC_L), TC_Med = lists:nth(round((TC_N - 1) / 2), lists:sort(TC_L)), TC_Avg = round(lists:foldl(fun(TC_X, TC_Sum) -> TC_X + TC_Sum end, 0, TC_L) / (TC_N - 1)), io:format("Range: ~b - ~b mics~nMedian: ~b mics ~nAverage: ~b mics~n", [TC_Min, TC_Max, TC_Med, TC_Avg]), TC_Med end. | |
% Made "cmd+v futon-ready" with the following disgusting display of black magic | |
% cat scratch.erl | sed 's/%.*//' | sed 's/"/\\"/'g | sed -e ':a' -e 'N' -e '$!ba' -e 's/\n/ /g' | pbcopy | |
fun ({Doc}, {Req}) -> | |
SafeGetValue = fun(Key, PropListMaybe, Default) -> |
{ | |
"folders": | |
[ | |
{ | |
"path": ".", | |
"folder_exclude_patterns": ["static/dist"] | |
} | |
] | |
} |
// NB: all three of these will have the same comment documentation | |
var minimumSig = function(start, mid, end) = { | |
var newMid; | |
if (arguments === 3) { | |
newMid = mid; | |
} else if (arguments === 4) { | |
newMid = arguments[2]; | |
end = arguments[3]; | |
} else { |
// NB: all three of these will have the same comment documentation | |
var minimumSig = function(start, mid, end) = { | |
var newMid; | |
if (arguments === 3) { | |
newMid = mid; | |
} else if (arguments === 4) { | |
newMid = arguments[2]; | |
end = arguments[3]; | |
} else { |
diff --git a/static/js/modules/send-message.js b/static/js/modules/send-message.js | |
index 7ffd075..3ce2443 100644 | |
--- a/static/js/modules/send-message.js | |
+++ b/static/js/modules/send-message.js | |
@@ -21,7 +21,7 @@ var _ = require('underscore'), | |
}; | |
var validatePhoneNumber = function(data) { | |
- if (data.everyoneAt) { | |
+ if (data.doc.everyoneAt) { |
#!/usr/bin/env /srv/software/medic-core/v1.6.1/x64/bin/node | |
var http = require('http'); | |
var request = function(options, postData, callback) { | |
if (!callback) { | |
callback = postData; | |
postData = null; | |
} |
I hereby claim:
To claim this, I am signing this object:
fn next_prime(given: &Vec<i32>) -> Option<i32> { | |
fn is_prime(given: &Vec<i32>, i: i32) -> bool { | |
given.iter().all(|&x| i % x != 0) | |
} | |
if let Some(next) = given.iter().last() { | |
let mut next = next + 1; | |
while !is_prime(given, next) { | |
next += 1; |
var randomBytes = require('crypto').randomBytes; | |
var RANDOM_GENERATORS = { | |
'randomUInt8Crypto': function() { | |
return randomBytes(1).readUInt8(); | |
}, | |
'randomUInt8Old': function() { | |
return 0 | Math.random() * 256; | |
} | |
}; |