- A = [xA, yA] is a point on the 2D plane. Same for B, C, ...
- lengths are in any unit (ex: pixels)
- code snippets are in JavaScript
angleRad = angleDeg * Math.PI / 180;
| # Sample toolchain file for building for Windows from an Ubuntu Linux system. | |
| # | |
| # Typical usage: | |
| # *) install cross compiler: `sudo apt-get install mingw-w64` | |
| # *) cd build | |
| # *) cmake -DCMAKE_TOOLCHAIN_FILE=~/mingw-w64-x86_64.cmake .. | |
| # This is free and unencumbered software released into the public domain. | |
| set(CMAKE_SYSTEM_NAME Windows) | |
| set(TOOLCHAIN_PREFIX x86_64-w64-mingw32) |
| #include <stdio.h> | |
| main(void) { | |
| \\ enter alternate screen mode | |
| printf("\033[?1049h"); | |
| \\ move the cursor to the upper left corner | |
| printf("\033[H"); | |
| printf("Hello, World"); | |
| package example | |
| import ( | |
| "fmt" | |
| "math/rand" | |
| "net/http" | |
| "google.golang.org/appengine" | |
| "google.golang.org/appengine/file" | |
| "google.golang.org/appengine/log" |
| ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | |
| ;;; 1. Example of using quicklisp to laod in | |
| ;;; cl-utilities and use one function | |
| ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | |
| ;;; Load in the cl-utilities package | |
| (ql:quickload "cl-utilities") | |
| ;;; Tell the cl-user namespace to use the cl-utilities package |
| package main | |
| import ( | |
| "fmt" | |
| "io" | |
| "os" | |
| ) | |
| var path = "/Users/novalagung/Documents/temp/test.txt" |
| // Implementation in ES6 | |
| function pagination(c, m) { | |
| var current = c, | |
| last = m, | |
| delta = 2, | |
| left = current - delta, | |
| right = current + delta + 1, | |
| range = [], | |
| rangeWithDots = [], | |
| l; |
EMOJI CHEAT SHEET
Emoji emoticons listed on this page are supported on Campfire, GitHub, Basecamp, Redbooth, Trac, Flowdock, Sprint.ly, Kandan, Textbox.io, Kippt, Redmine, JabbR, Trello, Hall, plug.dj, Qiita, Zendesk, Ruby China, Grove, Idobata, NodeBB Forums, Slack, Streamup, OrganisedMinds, Hackpad, Cryptbin, Kato, Reportedly, Cheerful Ghost, IRCCloud, Dashcube, MyVideoGameList, Subrosa, Sococo, Quip, And Bang, Bonusly, Discourse, Ello, and Twemoji Awesome. However some of the emoji codes are not super easy to remember, so here is a little cheat sheet. โ Got flash enabled? Click the emoji code and it will be copied to your clipboard.
People
๐
| /* | |
| * A simple example of json string parsing with json-c. | |
| * | |
| * clang -Wall -g -I/usr/include/json-c/ -o json_parser json_parser.c -ljson-c | |
| */ | |
| #include <json.h> | |
| #include <stdio.h> | |
| int main() { | |
| struct json_object *jobj; |