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
fun! s:use_eval(co) | |
let c = a:co | |
let r = eval('0x'.c[0].c[1]) | |
let g = eval('0x'.c[2].c[3]) | |
let b = eval('0x'.c[4].c[5]) | |
return [r,g,b] | |
endfunction | |
fun! s:without_eval(co) | |
let c = a:co |
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
function uniqueAndCount(list) { | |
var index = 0, | |
num = 0; | |
var result = []; | |
for (var i = 0; i < list.length; i++) { | |
if ($.inArray(list[i], result) < 0) { | |
result.push(list[i]); | |
while ($.inArray(list[i], list, index) > -1) { | |
num++; | |
index = $.inArray(list[i], list, index) + 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
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE | |
Version 2, December 2004 | |
Copyright (C) 2011 YOUR_NAME_HERE <YOUR_URL_HERE> | |
Everyone is permitted to copy and distribute verbatim or modified | |
copies of this license document, and changing it is allowed as long | |
as the name is changed. | |
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE |
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
#include <stdio.h> | |
#include <stdlib.h> | |
#include <assert.h> | |
typedef unsigned int u32; | |
typedef unsigned long long u64; | |
//------------------------------------------------------------------------- | |
// WorkArea | |
//------------------------------------------------------------------------- |
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 ffi = require('ffi'), | |
ref = require('ref'), | |
Struct = require('ref-struct'), | |
Library = require('./Library'), | |
Type = ref.Type, | |
NULL = ref.NULL, | |
isNull = ref.isNull; | |
var groups = ['libs', 'types', 'structs', 'callbacks', 'enums']; |
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
function uniqueArr(arr, juggfunc) { | |
var resArr = []; | |
var has = false; | |
for (var i = 0; i < arr.length; ++i) { | |
for (var j = 0; j < resArr.length; ++j) { | |
if( juggfunc(resArr[j], arr[i]) ){ | |
has = true; | |
} | |
} | |
if (has) { |
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
PAC script: data:application/x-ns-proxy-autoconfig;base64,LypPbWVnYVByb2ZpbGUqIlx1MDAyZnU4MWVhXHUwMDJmdTUyYThcdTAwMmZ1NTIwN1x1MDAyZnU2MzYyIioxNTBkZGViZTQ1NyovdmFyIEZpbmRQcm94eUZvclVSTD1mdW5jdGlvbihpbml0LHByb2ZpbGVzKXtyZXR1cm4gZnVuY3Rpb24odXJsLGhvc3QpeyJ1c2Ugc3RyaWN0Ijt2YXIgcmVzdWx0PWluaXQsc2NoZW1lPXVybC5zdWJzdHIoMCx1cmwuaW5kZXhPZigiOiIpKTtkb3tyZXN1bHQ9cHJvZmlsZXNbcmVzdWx0XTtpZih0eXBlb2YgcmVzdWx0PT09ImZ1bmN0aW9uIilyZXN1bHQ9cmVzdWx0KHVybCxob3N0LHNjaGVtZSl9d2hpbGUodHlwZW9mIHJlc3VsdCE9PSJzdHJpbmcifHxyZXN1bHQuY2hhckNvZGVBdCgwKT09PTQzKTtyZXR1cm4gcmVzdWx0fX0oIitcdTgxZWFcdTUyYThcdTUyMDdcdTYzNjIiLHsiK1x1ODFlYVx1NTJhOFx1NTIwN1x1NjM2MiI6ZnVuY3Rpb24odXJsLGhvc3Qsc2NoZW1lKXsidXNlIHN0cmljdCI7aWYoL15odHRwczpcL1wvLipcLmNsb3VkZnJvbnRcLm5ldFwvLy50ZXN0KHVybCkpcmV0dXJuIitzaGFkb3dzb2NrcyI7aWYoL15mZWVkbHlcLmNvbSQvLnRlc3QoaG9zdCkpcmV0dXJuIitzaGFkb3dzb2NrcyI7aWYoL15tYWlsXC5nb29nbGVcLmNvbSQvLnRlc3QoaG9zdCkpcmV0dXJuIitzaGFkb3dzb2NrcyI7aWYoL153d3dcLmdvb2dsZVwuY29tJC8udGVzdChob3N0KSlyZXR1cm4iK3NoYWRvd3NvY2tzIjtpZigvXmNvZGVcLmdvb2dsZVwuY2 |
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
" unclebill <billbill290@gmail.com> | |
function! Sdcv(...) | |
let s:keyword = "" | |
if a:0 == 0 | |
let s:keyword = expand("<cword>") | |
if s:keyword == "" | |
echo "sdcv: no keyword input" | |
return | |
endif | |
else |
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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<title></title> | |
<style type="text/css" media="screen"> | |
.box{ | |
height:30px; | |
width:30px; | |
border-radius:30px; |
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
;; zone-pgm-rainbow | |
(defun decimal->hex (n) | |
(format "%02X" n)) | |
(defun hsv->rgb (h s v) | |
(let ((h (max 0 (min 360 h))) | |
(s (/ (max 0 (min 100 s)) 100.0)) | |
(v (/ (max 0 (min 100 v)) 100.0))) | |
(if (= 0 s) |
OlderNewer