GNU Octave is a high-level interpreted language, primarily intended for numerical computations.
(via GNU Octave)
- not equal
~=
- logical AND
&&
#Install Gource in Ubuntu | |
======================== | |
#Go to the folder.... and | |
#see http://tylerfrankenstein.com/code/install-gource-ubuntu-1010-visualize-git-repo | |
sudo apt-get update | |
sudo apt-get install libsdl2-dev libsdl2-image-dev libpcre3-dev libfreetype6-dev libglew-dev libglm-dev libboost-filesystem-dev libpng12-dev libsdl1.2-dev libsdl-image1.2-dev libtinyxml-dev | |
./configure | |
make | |
sudo make install |
GNU Octave is a high-level interpreted language, primarily intended for numerical computations.
(via GNU Octave)
~=
&&
import scala.language.postfixOps | |
import scala.util.{Success, Failure} | |
import scala.concurrent.ExecutionContext.Implicits.global | |
import scala.concurrent.duration._ | |
import scala.concurrent._ | |
import scala.util.Try | |
import sys.process._ | |
import concurrent.Future | |
import concurrent.Promise |
<?php | |
error_reporting(E_ALL ^ E_NOTICE); | |
abstract class Option { | |
protected $value; | |
public function __construct($value) { | |
if (isset($value)) return some($value); | |
else return none(); | |
} |
// actions/action_select_contact.js | |
function selectContact(contact) { | |
return { | |
type: 'CONTACT_SELECTED', | |
payload: contact | |
} | |
} | |
export default selectContact; |
// reducer_active_contact.js | |
export default function(state = null, action) { | |
switch (action.type) { | |
case 'CONTACT_SELECTED': | |
return action.payload | |
} | |
// i dont care about the action because it is not inside my | |
// list of actions I am interested int (case statements inside the switch) | |
return state | |
} |
# code from: https://code.tutsplus.com/articles/what-is-genserver-and-why-should-you-care--cms-29143 | |
defmodule MathServer do | |
def start do | |
spawn &listen/0 | |
end | |
defp listen do | |
receive do | |
{:sqrt, caller, arg} -> send(caller, {:result, do_sqrt(arg)}) |
import scala.concurrent.Future | |
import scala.concurrent.ExecutionContext.Implicits.global | |
import scala.concurrent.duration._ | |
import scala.concurrent.Await | |
import github4s.Github | |
import github4s.Github._ | |
import github4s.GithubResponses.GHResult | |
import github4s.jvm.Implicits._ |
import akka.actor._ | |
import scala.concurrent.Await | |
import scala.concurrent.duration._ | |
object RebelAkktorsGist extends App { | |
/**************************** | |
* Messages * | |
***************************/ |
import scala.util.Try | |
object FizzBuzz { | |
def main(args: Array[String]): Unit = { | |
val iterations = Try(args(0).toInt).getOrElse(0) | |
(1 to iterations).foreach {i => | |
if (i % 15 == 0) println(s"$i - FizzBuzz") | |
else if (i % 3 == 0) println(s"$i - Fizz") | |
else if (i % 5 == 0) println(s"$i - Buzz") | |
else println(s"$i") |