{{ message }}

Instantly share code, notes, and snippets.

# Behrooz Nobakht nobeh

Created May 27, 2018 — forked from anonymous/gist:1406238
View gist:19211b556178c647594e81bb5fa2d798
 Originally: https://gist.github.com/7565976a89d5da1511ce Hi Donald (and Martin), Thanks for pinging me; it's nice to know Typesafe is keeping tabs on this, and I appreciate the tone. This is a Yegge-long response, but given that you and Martin are the two people best-situated to do anything about this, I'd rather err on the side of giving you too much to think about. I realize I'm being very critical of something in which you've invested a great deal (both financially
Last active Sep 7, 2015
Trigger Unix OOM Killer
View Killer.java
 public class Killer { static final long T0 = System.nanoTime(); static final java.util.Random R = new java.util.Random(System.nanoTime()); static java.util.logging.Logger LOGGER; static String ID; static class Data { // 8 bytes header long p1; // 8 bytes
Created Oct 5, 2014
Details of our apartment in Almere
View OurApartment
 # Welcome to our apartment! In the following, we have tried our best to provide all the necessary details that you may need as our guest. Thanks and enjoy! # Would you please ... * We have prepare a small rounded box for your breakfast. It's in the fridge. Don't forget that! * There are also other delights around and labelled. Enjoy! * When you enter the building, ensure the door closes after you. * Close the balcony door during night, when you are sleep or when you want to leave the apartment.
Created Oct 10, 2013
Java 8 Lambda Expression Language Syntax -- Reference: http://cr.openjdk.java.net/~dlsmith/jsr335-0.6.1/B.html
View java8-lambda.tex
 \begin{figure}[t] \begin{align} L ::=& \; L_P \; \to \; \{ \; L_B \; \} \\ L_P ::=& \; I \; | \; ( \: P_{\mathsf{list}}^? \: ) \; | \; ( \: P_{\mathsf{list}}^i \: ) \\ P_{\mathsf{list}}^i ::=& \; I \; | \; P_{\mathsf{list}}^i \; , \; I \\ L_B ::=& \; E \; | \; K \\ P_{\mathsf{list}} ::=& \; P_{\mathsf{last}} \; | \; P \; , \; P_{\mathsf{last}} \\ P ::=& \; P_{\mathsf{single}} \; | \; P \; , \; P_{\mathsf{single}} \\ P_{\mathsf{single}} ::=& \; F^? \; T \; I \\ P_{\mathsf{last}} ::=& \; F^? \; T... \; I \; | \; P_{\mathsf{single}} \\
Created Feb 5, 2012
Prime sieves with Scala Actors
View PrimeSieves.scala
 import scala.actors.Actor case class sieve(n: Int) case class finish(n: Int) class Sieve(val p: Int) extends Actor { var next: Sieve = null def _sieve(n: Int) = {
Created Feb 5, 2012
Prime sieves in Scala with Akka Actors
View AkkaPrimeSieves.scala
 import akka.actor._ import akka.actor.Actor._ case class sieve(n: Int) case class finish(n: Int) class SieveAkka(val p: Int) extends Actor { var next: ActorRef = null