git --help git <command> --help
git commit -am wip git commit -m "Initial commit" --allow-empty git commit --amend --allow-empty --no-edit
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Hello Page</title> | |
<script src="https://unpkg.com/[email protected]"></script> | |
<script src="https://unpkg.com/[email protected]/index.js"></script> | |
<script language="javascript"> | |
MockRequests.setDynamicMockUrlResponse('/ui/button', | |
{ |
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Hello Page</title> | |
<script src="https://unpkg.com/[email protected]"></script> | |
</head> | |
<body> | |
<h1>Hello</h1> |
. |
import doctest | |
from collections import namedtuple | |
import sys | |
def parse_string(target): | |
""" | |
>>> list(parse_string('foo')('foobar')) | |
[('foo', 'bar')] | |
>>> list(parse_string('foo')('bar')) |
module Main where | |
main :: IO () | |
main = print $ fb <$> [0..15] | |
fb :: Int -> String | |
fb n = fallthrough (show n) concat [ (n `mod` 3 == 0, "Fizz") | |
, (n `mod` 5 == 0, "Buzz") | |
] |
import Control.Applicative | |
import Data.List | |
newtype Parser a = Parser { runParser :: String -> [(a, String)] } | |
parseConst :: a -> Parser a | |
parseConst a = Parser $ \s -> [(a, s)] | |
parseString :: String -> Parser String | |
parseString target = Parser p where |
from collections import namedtuple | |
Lazy = namedtuple('Lazy', 'force') | |
def parseConst(a): | |
""" | |
>>> parseConst(1)('') | |
[(1, '')] | |
""" |
object App { | |
// this integer references can be avoided when/if SIP-23 - Literal-based | |
// singleton types is implemented | |
val _1 = 1: Integer | |
val _2 = 2: Integer | |
val _3 = 3: Integer | |
// ... up to 22 | |
trait TupleGet[T, A, N <: Integer] { |
{-# LANGUAGE DataKinds #-} | |
{-# LANGUAGE KindSignatures #-} | |
{-# LANGUAGE PolyKinds #-} | |
{-# LANGUAGE ScopedTypeVariables #-} | |
{-# LANGUAGE GeneralizedNewtypeDeriving #-} | |
module Main where | |
import Data.Proxy | |
import GHC.TypeLits |