This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(echo '"Date","Amount","Account Name"' ; tail -n +2 ~/Downloads/trends.csv | sed -e 's/January /01-/' -e 's/February /02-/' -e 's/March /03-/' -e 's/April /04-/' -e 's/May /05-/' -e 's/June /06-/' -e 's/July /07-/' -e 's/August /08-/' -e 's/September /09-/' -e 's/October /10-/' -e 's/November /11-/' -e 's/December /12-/' -e 's/"\(.*\)","\$\(.*\)",".*",".*"/"\1","\2","ACCOUNT_NAME_HERE"/' -e 's/^"\([0-9]\+\)-\([0-9]\+\)/"\2-\1-01/') > /tmp/balances.csv |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from ortools.sat.python import cp_model | |
from ortools.sat.cp_model_pb2 import CpSolverStatus | |
num_lectors = 4 | |
num_groups = 3 | |
num_lessons_per_day = 3 | |
num_days = 5 | |
model = cp_model.CpModel() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
VL53L1X_ERROR VL53L1X_SensorInit(uint16_t dev) | |
{ | |
VL53L1X_ERROR status = 0; | |
uint8_t Addr = 0x00, tmp; | |
for (Addr = 0x2D; Addr <= 0x87; Addr++){ | |
status = VL53L1_WrByte(dev, Addr, VL51L1X_DEFAULT_CONFIGURATION[Addr - 0x2D]); | |
} | |
status = VL53L1X_StartRanging(dev); | |
tmp = 0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{-# Language TypeFamilies, StandaloneDeriving, GeneralizedNewtypeDeriving, UndecidableInstances #-} | |
module Example where | |
newtype N p m a = N (((CT p) m) a) | |
deriving instance (CT p ~ f, Functor (f m)) => Functor (N p m) | |
deriving instance (CT p ~ f, Applicative (f m)) => Applicative (N p m) -- internal error when this line added | |
class C p where | |
type CT p :: (* -> *) -> * -> * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Foo(a: Int) { | |
def bar(other: Foo) { | |
other match { | |
case f : Foo => println(f.a) | |
} | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// LockedWindow.cpp : Defines the entry point for the application. | |
// | |
#include "stdafx.h" | |
#include "LockedWindow.h" | |
#define MAX_LOADSTRING 100 | |
// Global Variables: | |
HINSTANCE hInst; // current instance |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{-# Language MultiParamTypeClasses, PolyKinds #-} | |
module Monads where | |
import Control.Monad.Reader | |
import Data.Binary.Get | |
import Data.Proxy | |
import qualified Data.ByteString.Lazy as BS | |
type ReadContext = String | |
type MyGetM m = ReaderT ReadContext m |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{-# LANGUAGE GeneralizedNewtypeDeriving #-} | |
import qualified Data.Binary.Get as G | |
type BGetM = ReaderT SchemaDef G.Get | |
newtype BGet t a = BGet (BGetM a) | |
deriving (Functor, Applicative, Monad) | |
class Proto t where | |
bGetInt32 :: BGet t Int32 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module A where | |
data InnerType = InnerType { foo :: Int } | |
inVar :: OuterType | |
inVar = OuterType (InnerType 2) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-----BEGIN RSA PRIVATE KEY----- | |
Proc-Type: 4,ENCRYPTED | |
DEK-Info: AES-128-CBC,C57436288A327D03B9C7B2607E088092 | |
Nil8Qg2o7TFLIyG2zqwjhbAzOYcGuRJfeWsDuG1xQTRJtdxDhglDjlmWSdKmaUPZ | |
cPUgsU2oO/N1IoVbseqL0newhUvsU9RyOeXQD41gjGjxBYsKV69v7FFQ6Upw0plR | |
oS2vj637pr2Ax63DwkhPMSubCaC4p1o48FYYGjim4FTcPjvZbnD9d1f2MCA8O6mZ | |
8Wc+Tk7kF6D3qZUMfw4gixc2ft1ImRIQ5f5ReXHhP3IPpbZfpZbe0Q8lkTiOPIQu | |
9FdeLMXQZBMENCnIegi1+cI3x6uBcAP4TpXgkXQg8PFQ18epT9epTcMzr7rjLQpd | |
pWDCO+tqSlzTtknPq4kBQGnbXJ50uRw/kjBMK9DGjU5zO5dvXnk9DMU4N9jMPKzh |
NewerOlder