Recommendations of unit types per media type:
| Media | Recommended | Occasional use | Infrequent use | Not recommended |
|---|---|---|---|---|
| Screen | em, rem, % | px | ch, ex, vw, vh, vmin, vmax | cm, mm, in, pt, pc |
| em, rem, % | cm, mm, in, pt, pc | ch, ex | px, vw, vh, vmin, vmax |
| ; Short guide to TCP/IP Client/Server programming in Common Lisp using usockets | |
| ; | |
| ; The main reason for this guide is because there are very few examples that | |
| ; explain how to get started with socket programming with Common Lisp that I | |
| ; could understand. After spending a day trying, I finally came up with a small | |
| ; bit of code that makes it easy to understand the basics. I've written this | |
| ; primarily for myself, but should help others get started as well. | |
| ; As usual, we will use quicklisp to load usocket. |
| // Option 1: require inline | |
| var app = express(); | |
| app.get('/', require('routes/index')); | |
| app.get('/login', require('routes/login').index); | |
| app.post('/login', require('routes/login').do_login); | |
| // Easy to split up routes | |
| // Centralized route paths |
| /* Quackmatic 2014 | |
| * https://github.com/Quackmatic | |
| */ | |
| #include <math.h> | |
| #include "vector2.h" | |
| vec2 vec_add(vec2 v1, vec2 v2) | |
| { | |
| vec2 value = { v1.x + v2.x, v1.y + v2.y }; |
| package main | |
| import ( | |
| "fmt" | |
| "os" | |
| "path/filepath" | |
| ) | |
| func main() ([]string, error) { | |
| searchDir := "c:/path/to/dir" |
Recommendations of unit types per media type:
| Media | Recommended | Occasional use | Infrequent use | Not recommended |
|---|---|---|---|---|
| Screen | em, rem, % | px | ch, ex, vw, vh, vmin, vmax | cm, mm, in, pt, pc |
| em, rem, % | cm, mm, in, pt, pc | ch, ex | px, vw, vh, vmin, vmax |
| package main | |
| import ( | |
| "fmt" | |
| "log" | |
| "net/http" | |
| "html/template" | |
| "github.com/gorilla/sessions" |
| package main | |
| import ( | |
| "net/http" | |
| "database/sql" | |
| "fmt" | |
| "log" | |
| "os" | |
| ) |
| from math import * | |
| """ | |
| easeInBack: function (x, t, b, c, d, s) { | |
| if (s == undefined) s = 1.70158; | |
| return c*(t/=d)*t*((s+1)*t - s) + b; | |
| }, | |
| easeOutBack: function (x, t, b, c, d, s) { |
| #!/usr/bin/env python | |
| """Basic Python Cheat Sheet by Filip Kral on 2015/02/16""" | |
| """ | |
| Python is a cross-platform, interpreted, object-oriented programming language. | |
| That means you can run it on Linux, Windows, Mac, and other platforms, | |
| you don't need to compile your code to execute it because it is compiled on | |
| the fly, and you can use classes and objects. |