Skip to content

Instantly share code, notes, and snippets.

Avatar

chessai chessai

View GitHub Profile
View gist:fcde80787c2623e05e059bffd4bd6906
/nix/store/m1kb6fz7sbilmqw96w74aswgbqc9kiim-bash-4.4-p23-dev
/nix/store/dpiqx8km6kaf9v1kpavdmmy1yb149c98-bash-4.4-p23-doc
/nix/store/fky90f457av1jf9jlrlh7r60zcd8fpfs-bash-4.4-p23-info
/nix/store/mwvrsjsca4wbnwdggdn30bdmrc8ssxf3-bash-4.4-p23-man
/nix/store/qvm6bs79rsychid8xxwpyn23kapszmk5-bash-4.4-p23
/nix/store/128cyl1jys9nb3a373cx6j1mhx2rgpga-coreutils-8.31-info
/nix/store/sc8d93z8sc776j1qh1f8cq4y3cngmsbb-coreutils-8.31
/nix/store/hsgl306w10wnrqsmrjb3824g1bhx3n1c-gnused-4.8-info
/nix/store/wf9x52iznlnb9kq8i86dd1mx56j7f6mg-gnused-4.8
/nix/store/n6zydd3937r8fx2dppw10lhz4vsxjzpf-stdenv-darwin
View Models.swift
//swiftlint:disable line_length type_name
//
// DO NOT EDIT THIS FILE
// IT HAS BEEN AUTOMATICALLY GENERATED
// BY THE FOLLOWING CODE: https://github.com/MercuryTechnologies/mercury-web-backend
// AT TIME: 2021-01-25T19:56:58 UTC
//
import Foundation
View prop.hs
{-# language QuasiQuotes #-}
import Examples.Sudoku
import Text.RawString.QQ (r)
-- | The world's hardest sudoku problem, with only 4 starting numbers.
-- Found here: youtube.com/watch?v=hAyZ9K2EBF0
ultimateProblem :: String
ultimateProblem = [r|
.........
View haskell.hs
data M (a :: k) = MkM
getShwifty ''M
data OneTyVar a = OneTyVar
{ one :: Either (Maybe a) (Maybe a)
, two :: Maybe (Maybe (Maybe (Maybe a)))
}
getShwifty ''OneTyVar
data K a = K { getK :: a, getInt :: Int }
View Layer3JobPosting.md

Programmer: Atlanta, GA, No Remote, Full-Time

Layer 3 Communications is a professional services organization and network systems integrator. We use Haskell to build network security applications that revolve around either analyzing network data or configuring networks.

Networking knowledge can be learned on the job, and thus is not required.

Our stack:

  • Backend: Haskell
  • Frontend: Small amounts of JavaScript
  • Database: Postgres
View regex.hs
data Regex t
= RegexLiteral t t
--^ low and high, inclusive
| RegexEmpty
| RegexRejection
| RegexUnion (Regex t) (Regex t)
| RegexAppend (Regex t) (Regex t)
| RegexStar (Regex t)
instance Semiring (Regex t) where
View gist:86ead95bf00faeeb411b55a59c5c98f7
/nix/store/yhlyxjn0s57g0y18gnmak9fj33ynff5h-ghc-8.6.5-with-packages/lib/ghc-8.6.5/package.conf.d
Cabal-2.4.0.1
HUnit-1.6.0.0
QuickCheck-2.12.6.1
RSA-2.3.1
SHA-1.6.4.4
StateVar-1.1.1.1
adjunctions-4.4
aeson-1.4.4.0
ansi-terminal-0.9.1
@chessai
chessai / conv.hs
Created Oct 4, 2019
bytearray <===> bytestring
View conv.hs
-- | Like 'unsafeByteArrayToByteString', but might perform a copy
-- if the 'ByteArray' is not pinned.
byteArrayToByteString :: ByteArray -> ByteString
byteArrayToByteString b@(ByteArray b#)
| isTrue# (isByteArrayPinned# b#) = unsafeByteArrayToByteString b
| otherwise = runST $ do
let len = sizeofByteArray b
marr@(MutableByteArray marr#) <- newPinnedByteArray len
copyByteArray marr 0 b 0 len
View justin_is_a_baller.bash
xrandr --output eDP-1 --fb 1280x720 --mode 1920x1080 --scale-from 1280x720 --output HDMI-1 --scale 1x1 --mode 1280x720 --same-as eDP-1
View yeet.cpp
#include <iostream>
#define yeet int
#define Yeet main
#define yEet std
#define yeEt cout
#define yeeT return
#define Yeeet (
#define yeeeT )
#define Yeeeet {