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
$.ajax({ | |
url: "Service/request", | |
async: false, | |
type: "POST", | |
dataType: "json", | |
contentType: "application/json", | |
data: JSON.stringify(obj), | |
cache: false, | |
success: function (data) { | |
alert(data); |
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
--[[ Implementation of MergeSort --]] | |
-- main mergesort algorithm | |
function mergeSort(A, p, r) | |
-- return if only 1 element | |
if p < r then | |
local q = math.floor((p + r)/2) | |
mergeSort(A, p, q) | |
mergeSort(A, q+1, r) | |
merge(A, p, q, r) |
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
// to check if the exe is running in debug mode use: | |
#if DEBUG | |
// put code to run in debugmode | |
#endif |
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
char one[8][4] = {{0, 0, 1, 0}, | |
{0, 0, 1, 0}, | |
{0, 0, 1, 0}, | |
{0, 0, 1, 0}, | |
{0, 0, 1, 0}, | |
{0, 0, 1, 0}, | |
{0, 0, 1, 0}, | |
{0, 0, 1, 0}}; | |
char two[8][4] = {{1, 1, 1, 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
#include <stdlib.h> | |
#include <MeggyJrSimple.h> | |
byte screen[8][8] = {{0,0,0,0,0,0,0,0}, | |
{0,0,0,0,0,0,0,0}, | |
{0,0,0,0,0,0,0,0}, | |
{0,0,0,0,0,0,0,0}, | |
{0,0,0,0,0,0,0,0}, | |
{0,0,0,0,0,0,0,0}, | |
{0,0,0,0,0,0,0,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
gcc -Wall -shared -I/usr/local/include/ -L/usr/local/lib/ -llua -o serial.so serial.c |
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
$.postify = function(value) { | |
var result = {}; | |
var buildResult = function(object, prefix) { | |
for (var key in object) { | |
var postKey = isFinite(key) | |
? (prefix != "" ? prefix : "") + "[" + key + "]" | |
: (prefix != "" ? prefix + "." : "") + key; |
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
gcc -Wall -shared -I/mnt/storag | |
e/Lua/include/ -L/mnt/storage/Lua/lib/ -llua -lm -ldl -o screen.so screen.c |
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
local g = love.graphics | |
PagerList = { | |
rowsPerPage = 4, | |
spaceBetweenRow = 44, | |
initSpace = 24, | |
noPages = 0, | |
currentPage = 0, | |
noRows = 0, | |
rowsToDisplay = 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
luaL_newmetatable(L, SCREENMETA); |