Refer to http://www.phoenixframework.org/docs/installation for installing Phoenix and dependencies.
mix phoenix.new hello_phoenix
# ...
Fetch and install dependencies? [Yn] y
| type MapToIterable<T> = { [K in keyof T]: Iterable<T[K]> }; | |
| type Tuple = readonly unknown[]; | |
| export function from<T>(it: Iterable<T>) { | |
| return new DelegatingIterable<T>(it); | |
| } | |
| export function repeat<T>(value: T) { | |
| return new RepeatIterable(value); | |
| } |
| /* | |
| * zipWith(...arrays, iteratee, [thisArg]) => array | |
| * | |
| * iteratee receives an element from each array as an argument | |
| */ | |
| function zipWith() { | |
| // Argument count | |
| var argc = arguments.length; |
Refer to http://www.phoenixframework.org/docs/installation for installing Phoenix and dependencies.
mix phoenix.new hello_phoenix
# ...
Fetch and install dependencies? [Yn] y
| #include <stdio.h> | |
| #include <string.h> | |
| // serializing macros | |
| #define serialize1(name, t1) void name(char* buffer, t1 a) { \ | |
| memcpy(buffer, &a, sizeof(t1)); } | |
| #define serialize2(name, t1,t2) void name(char* buffer, t1 a, t2 b) { \ | |
| memcpy(buffer, &a, sizeof(t1)); \ | |
| memcpy(buffer + sizeof(t1), &b, sizeof(t1)); } |
| /* | |
| Coded by Santiago Jaramillo 2012 | |
| Connection setup: | |
| === ITG-3200 === | |
| VDD -> 3.3V | |
| VIO -> 3.3V | |
| GND -> GND | |
| SDA -> A4 |
| require 'fast_stemmer' | |
| require 'set' | |
| class BayesClassifier | |
| def initialize(categories) | |
| raise "categories must be an Array" unless categories.is_a? Array | |
| raise "At least 2 categories are needed" if categories.size < 2 | |
| @categories = categories.clone.freeze |
| #include <Servo.h> | |
| // El numero de motores | |
| static const unsigned int numServos = 2; | |
| // Los motores, sus pins, y su posicion actual | |
| static Servo servos[numServos]; | |
| static unsigned int servoPins[numServos] = {9,10}; | |
| static unsigned int servoPos[numServos] = {0}; |
| -------------------------------- | |
| -- StringBuffer (for printing out Trees) | |
| -------------------------------- | |
| local stringBuffer | |
| do | |
| local function insert(buffer, item) | |
| local len = buffer.length + 1 | |
| buffer.length = len | |
| buffer[len] = item | |
| end |
| <!doctype html> | |
| <html> | |
| <head> | |
| <meta charset="utf-8"> | |
| <title>WebRTC p2p data</title> | |
| <script src="https://webrtc-samples.googlecode.com/svn/trunk/apprtc/js/adapter.js"></script> | |
| </head> | |
| <body> | |
| Testing WebRTC connection. |
| // Audio Buffer Source | |
| var fileInput = $("#audio-file"); | |
| bufferSource.gain.value = 1; | |
| bufferSource.loop = true; | |
| bufferSource.connect(oscillatorGain); | |
| fileInput.addEventListener("change", function() { | |
| var reader = new FileReader(); | |
| reader.onload = function(ev) { | |
| context.decodeAudioData(ev.target.result, function(buffer) { |