Skip to content

Instantly share code, notes, and snippets.

View osvein's full-sized avatar

Oskar Sveinsen osvein

  • Norway
View GitHub Profile
@osvein
osvein / rotate.c
Created May 1, 2018 15:21
O(n) time, O(1) size array rotation
void
rotate(char *first, char *newfirst, char *end)
{
char *next;
next = newfirst;
while (next != first) {
char swap;
swap = *first;
Steely Dan - Home at Last
G minor
intro
F G A# D (Gm7)
G A C - (C6)
F G A# D (Gm7)
G A C E (C6)
A A# D F (A#maj7)
syntax "papyrus" "[.]psc$"
header "^[Ss][Cc][Rr][Ii][Pp][Tt][Nn][Aa][Mm][Ee][[:space:]]"
comment ";"
# Keywords
icolor green "\<(bool|customeventname|float|int|scripteventname|string|structvarname|var)\>"
icolor brightyellow "\<(else(if)?|(end)?(if|while))\>"
icolor brightcyan "\<import\>"
icolor brightgreen "\<(scriptname|customevent|(end)?(event|function|group|property|state|struct))\>"
icolor blue "\<(auto(readonly)?|(beta|debug)only|const|global|native)\>"
e|---------------------------------------|
B|----------------------------3---6---6--|
G|----------------2---5---3--------------|
D|--3---5-3---3--------------------------|
A|---------------------------------------|
E|---------------------------------------|
e|---------------------------------------|
B|--5--3---------------------------------|
G|--------5-------3--2----------------2--|
@osvein
osvein / bigiron.tab
Last active February 9, 2018 16:38
Marty Robbins - Big Iron, vocals arranged for guitar
e|-------------7---7---7-------------|-----------------------------------|
B|---5h7---9---------------9p5-------|---5h7---9----------------(5)------|
G|-----------------------------------|-------------6---6---4---6---------|
D|-----------------------------------|-----------------------------------|
A|-----------------------------------|-----------------------------------|
E|-----------------------------------|-----------------------------------|
* To the town of Agua Fria * rode a stranger one fine day *
e|-------------7---7---7-------------|---------------------7--(7h)9------|
B|---5h7---9---------------9p5-------|---5h7---9---5---9-----------------|
@osvein
osvein / mia.tab
Last active January 30, 2018 20:03
e|--------------3---------------3/6-------8-------6-------3---|
B|------4---6-----------6---4---------4---------------4-------|
G|--3---------------------------------------------------------|
D|------------------------------------------------------------|
A|------------------------------------------------------------|
E|------------------------------------------------------------|
e|--------------3---------------3/6---------------------------|
B|------4---6-----------6---4---------4---6-------------------|
G|--3---------------------------------------------------------|
@osvein
osvein / mutiny.tab
Last active January 30, 2018 20:03
e|-------------------------------------|
B|-------------------------------------|
G|---1---1---1-0-1-3-4---4---4-3-1-3---|
D|-------------------------------------|
A|-------------------------------------|
E|-------------------------------------|
e|-------------------------------------|
B|-------------------------------------|
G|---4---4---4---1---6---6---6-8-------|
#include <stdio.h>
#define READ2() (data
const char magic[] = { 0xDE, 0xC0, 0x57, 0xFA }; /* 0xFASTCODE */
char
pass1(void)
{
}
{
e|-------------------------------------------|
B|---5------5-5-4---3---2---2---2---2--------|
G|-------------------------------(3)--2(/3)--|
D|-------------------------------------------|
A|-------------------------------------------|
E|-------------------------------------------|
e|---2---2---2-0-2-3-4---4---4---------------|
B|-----------------------------2-3---4---2---|
e|-----5---5---4h5---7---5---2-----------------------------------------|
B|-------------------------------5--3---3---2ph3---5---3---------------|
G|---------------------------------------------------------4---2-------|
D|---------------------------------------------------------------------|
A|---------------------------------------------------------------------|
E|---------------------------------------------------------------------|
e|--------------2---4--4h5---2-----------------------------------------|
B|--2---3---5--------------------5-------------------------------------|
G|---------------------------------------------------------------------|