Skip to content

Instantly share code, notes, and snippets.

#include <stdio.h>
#include <stdlib.h>
#include <vector>
#include <chrono>
#include <thread>
#include <mutex>
#include <iostream>
using namespace std;
let f a b _ =
a + b
let f2 a =
f a 1
let () =
print_int (f 1 2 3);
print_newline ();
From 51f165b05a354ea047aca4436c191c2008d5058d Mon Sep 17 00:00:00 2001
From: MATSUZAKI Kensuke <zakki@peppermint.jp>
Date: Fri, 12 Jun 2015 17:39:11 +0900
Subject: [PATCH] Fix drawing
---
Makefile | 2 +-
graph.ml | 11 +++++++----
2 files changed, 8 insertions(+), 5 deletions(-)
hsp3dish/emscripten/hgiox.cpp | 12 ++++++++++++
hsp3dish/hgio.h | 2 ++
hsp3dish/hsp3gr_dish.cpp | 5 +++++
3 files changed, 19 insertions(+)
diff --git a/hsp3dish/emscripten/hgiox.cpp b/hsp3dish/emscripten/hgiox.cpp
index 428f5d1..d22b885 100644
--- a/hsp3dish/emscripten/hgiox.cpp
+++ b/hsp3dish/emscripten/hgiox.cpp
@@ -662,6 +662,18 @@ int hgio_getHeight( void )
(defvar *howm-truname-cache* nil)
(defun howm-file-truename (filename)
(or
(cdr (assoc filename *howm-truname-cache*))
(let ((f (file-truename (expand-file-name filename))))
(add-to-list '*howm-truname-cache* (cons filename f))
f)))
(defun howm-normalize-file-name (filename)
open Domain
let rec f i n =
if n mod 1000 = 0 then
Printf.printf "%d %d\n" i n;
f i (n + 1)
let () =
for i = 0 to 3 do
Printf.printf "%d\n" i;
import javafx.application.Application;
import javafx.scene.AmbientLight;
import javafx.scene.Group;
import javafx.scene.PerspectiveCamera;
import javafx.scene.PointLight;
import javafx.scene.Scene;
import javafx.scene.paint.Color;
import javafx.scene.paint.PhongMaterial;
import javafx.scene.shape.Box;
import javafx.scene.shape.CullFace;
@zakki
zakki / holderko.js
Created October 30, 2014 06:38
holder.js with knockout.js
ko.bindingHandlers["holderJs"] = {
init: function (element, valueAccessor) {
var value = valueAccessor();
$(element).attr("data-src", ko.unwrap(value));
Holder.run({ images: element });
}
};
class A {
public a() {
alert("A!");
}
}
class B extends A {
public b() {
alert("B!");
}
}
//from http://yosuke-furukawa.hatenablog.com/entry/2014/07/31/093041
$traceurRuntime.ModuleStore.getAnonymousModule(function() {
"use strict";
var $__2 = $traceurRuntime.initGeneratorFunction(fibonacci);
function fibonacci() {
var fn1,
fn2,
current;
return $traceurRuntime.createGeneratorInstance(function($ctx) {
while (true)