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
trait Repr[T] | |
trait ExpSym[Num, repr[_]] { | |
def lit: Num => repr[Num] | |
def neg: repr[Num] => repr[Num] | |
def add: repr[Num] => repr[Num] => repr[Num] | |
} | |
trait MulSym[Num, repr[_]] { |
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
# xorg.conf (X.Org X Window System server configuration file) | |
# | |
# This file was generated by dexconf, the Debian X Configuration tool, using | |
# values from the debconf database. | |
# | |
# Edit this file with caution, and see the xorg.conf manual page. | |
# (Type "man xorg.conf" at the shell prompt.) | |
# | |
# This file is automatically updated on xserver-xorg package upgrades *only* | |
# if it has not been modified since the last upgrade of the xserver-xorg |
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
import scalaz.Monoid | |
import scala.language.higherKinds | |
import scalaz.syntax.monoid._ | |
import scalaz.std.set._ | |
implicit def mm[K, T, M[_]](implicit mo: Monoid[M[T]]): Monoid[Map[K, M[T]]] = new Monoid[Map[K, M[T]]] { | |
def zero = Map.empty | |
def append(m1: Map[K, M[T]], m2: => Map[K, M[T]]) = { | |
val mMin = List(m1, m2).minBy(_.size) |
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
# Maintainer: Franois Garillot ("huitseeker") <francois [at] garillot.net> | |
# Contributor: Christian Krause ("wookietreiber") <kizkizzbangbang@gmail.com> | |
pkgname=apache-spark | |
pkgver=1.3.0 | |
pkgrel=3 | |
pkgdesc="fast and general engine for large-scale data processing" | |
arch=('any') | |
url="http://spark.apache.org" | |
license=('APACHE') |
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
#!/bin/sh | |
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" | |
brew install caskroom/cask/brew-cask | |
brew tap caskroom/versions | |
brew cask install google-chrome | |
brew cask install sublime-text3 |
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
HN: hyphothesis | |
AN: Axioms/Rules | |
H1: most minners uses top hardware 5 [TH/s] at 3600 [W] (best case) | |
source: https://en.bitcoin.it/wiki/Mining_hardware_comparison | |
H2: at ~5 [TH/s] it's expected to generate 0.05 [BTC/d] | |
source: https://alloscomp.com/bitcoin/calculator | |
A1: rule: 25 BTC/block |
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
network={ | |
ssid="UdeM avec cryptage" | |
scan_ssid=1 | |
key_mgmt=WPA-EAP NONE | |
pairwise=CCMP | |
group=CCMP TKIP | |
eap=TTLS PEAP TLS | |
identity="_____________@umontreal.ca" # << TODO | |
password="_____________" # << TODO | |
ca_cert="/etc/ssl/certs/ca-bundle.crt" # << TODO |
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
#! /bin/sh | |
SOURCE=tictactoe.cpp | |
SOURCE_TMP=tmp_tictactoe.cpp | |
DIFF_FAIL="ok" | |
COMPILE_FAIL="ok" | |
cp $SOURCE $SOURCE_TMP | |
#test patches | |
for diff in *.diff |
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
void Radio::playTrack( string fileTrack ) | |
{ | |
systeme_->createStream( fileTrack.c_str(), FMOD_ACCURATETIME, false, &sound_ ); | |
systeme_->playSound( FMOD_CHANNEL_FREE, sonRadio_, false, &channel_ ); | |
} | |
void Radio::update() | |
{ | |
bool playing = false; | |
if( channel_ ->isPlaying(&playing) != FMOD_OK ) |
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
// source: http://aperiodic.net/phil/scala/s-99/ | |
def isPalindrome[A](in: List[A]):Boolean = in == in.reverse | |
// source: https://github.com/dadrox/scala.katas (adapted for spec2) | |
import org.junit._ | |
import org.specs2.matcher._ | |
class NinetyNineScalaProblems extends JUnitMustMatchers { | |
@test def P06 | |
{ | |
isPalindrome Nil must beTrue |