Skip to content

Instantly share code, notes, and snippets.

That function takes s, an object formatted like this:

{
    lines = {
        { {colours.white, colours.grey, "Hello "}, {colours.white, colours.red, "world"}, {colours.white, colours.grey, "!"} };
        { {colours.white, colours.grey, "Hello "}, {colours.white, colours.green, "world"}, {colours.white, colours.grey, "!"} };
        { {colours.white, colours.grey, "Hello "}, {colours.white, colours.blue, "world"}, {colours.white, colours.grey, "!"} };
    };
    halign = text.ALIGN_CENTRE;
 valign = text.ALIGN_TOP;
class FunctionType = function int();
class C {
int f() {
return 1;
}
FunctionType f = function() {
return 1;
class FunctionType = function int();
class C {
int f() {
return 1;
}
FunctionType f = function() {
return 1;
local sheets = dofile "sheets.lua"
local tile
local application = sheets.Application()
local screen = application.screen
local container = screen + sheets.ScrollContainer( 0, 3, screen.width, screen.height - 3 )
do
local h = fs.open( "tile.lua", "r" )
local content = h.readAll()
@exerro
exerro / style.css
Created November 6, 2016 16:51
Howl.ci style
p {
color: rgba(0, 0, 0, 0.8);
font-weight: 400;
}
a {
font-weight: 400 !important;
}
public class BackPropagationNetwork
{
#region Constructors
public BackPropagationNetwork(int[] layerSizes, TransferFunction[] transferFunctions)
{
// Validate the input data
if (transferFunctions.Length != layerSizes.Length || transferFunctions[0] != TransferFunction.None)
local function guard(x)
if "" ~= select(2, pcall(error, "", 250)) then
error({ type = 'continuation', x })
else
return x()
end
end
local function exec(fn, ...)
local ok, err = pcall(fn, ...)
@exerro
exerro / Flux word occurrences
Last active September 4, 2016 00:02
Me being indescribably bored.
self: 700 occurrences
source: 592 occurrences
lexer: 527 occurrences
position: 486 occurrences
if: 314 occurrences
string: 301 occurrences
name: 268 occurrences
skip: 218 occurrences
let: 214 occurrences
value: 210 occurrences
local PATH = "Images"
local SORT_PATH = "Sorted"
local imagelist = {}
local categories = {
["i"] = "interior other";
["e"] = "exterior other";
["p"] = "people";
["b"] = "product";
["f"] = "the food";
function DrawAdapter:drawEllipse(x, y, width, height, colour, char, txtColour)
expect(x, "number", 1)
expect(y, "number", 2)
expect(width, "number", 3)
expect(height, "number", 4)
expect(colour, "number", 5)
expect(char, "string", true, 6)
expect(txtColour, "number", true, 7)