Skip to content

Instantly share code, notes, and snippets.

View tnoda's full-sized avatar

Takahiro Noda tnoda

View GitHub Profile
@tnoda
tnoda / fizzbuzz.org
Last active August 29, 2015 14:15
The FizzBuzz Question in the Imedio

The FizzBuzz Question in the Imedio

Imedians who originate from the planet Imedio love games of the Earth. The FizzBuzz Question is one of the most popular game among them, and is the winner of Imedian Game of the Year 2014.

Its rule is defined in a Wikipedia article as follows:

@tnoda
tnoda / page17.clj
Last active August 29, 2015 14:12
The id-mat function in page 17 of the book, "Clojure for Machine Learning" by Akhil Wali, does not work.
(defn id-mat
"Creates an identity matrix of n x n size"
[n]
(let [init (square-mat n 0 :implementation :clatrix)
identity-f (fn [i j n]
(if (= i j) 1 n))]
(cl/map-indexed identity-f init)))
;; clj-ml1.matrix-basics> (id-mat 5)
;; A 5x5 matrix
@tnoda
tnoda / proposal.org
Last active August 29, 2015 14:10
#scala_kb proposal

12/13(土) 第1回 Scala 関西勉強会プロポーザル

プロポーザル

12/13(土) 第1回 Scala 関西勉強会.次の (1) か (2) のどちらかを予定.

(1) Competitive Scala Programming

前回の

(let [v ["ジョ" "ン" "ボ" "ヴィ"]
a (reverse ["ジョン" "ボン" "ジョヴィ"])
s (->> (repeatedly #(str (rand-nth v) (rand-nth v)))
(reductions #(cons %2 %) [])
(drop-while #(not= a (take 3 %)))
first)]
(println (->> (reverse s)
(interpose "・")
(apply str))
"\n"
@tnoda
tnoda / proposal.md
Last active August 29, 2015 14:07
Clojure 夜会プロポーザル

Clojure 夜会 LT プロポーザル

次の 1--3 のどれかで LT したいです.

  1. CodinGame チュートリアルをライブコーディング
    • CodinGame についての簡単な説明
    • チュートリアル問題の解説
    • チュートリアル問題をライブコーディング
  • ネットワーク繋らないとつらい (WiMAX ルータを持っていく予定)

ぼっち.scala --- 「ぼっち」でも始められる Scala

第4回 Scala 関西ビギナーズ (session|LT) の提案.

概要

Scala はその人気の高まりとともに世界的には普及期に入りつつある. 日本においても,東京都心の D 社や D 社などを中心に Scala プログラマーが増えつつある. しかし,関西を含むほとんどの地域では Scala プログラマーお人口密度が低く,

$ make recipes/helm-ad
• Building recipe helm-ad ...
emacs --no-site-file --batch -l package-build.el --eval "(let ((package-build-stable nil) (package-build-archive-dir (expand-file-name \"./packages\" pb/this-dir))) (package-build-archive 'helm-ad))"
Error reading recipe /Users/tnoda/work/melpa/recipes/helm-ad~: Recipe 'helm-ad~' contains mismatched package name 'helm-robe'
;;; helm-ad
Fetcher: github
Source: tnoda/helm-ad
@tnoda
tnoda / mon-css-color.el
Created July 28, 2014 06:09
Mirror mon-css-color.el
;;; mon-css-color.el --- Highlight and edit CSS colors
;; -*- mode: EMACS-LISP; -*-
;;; ================================================================
;; Copyright © 2009, 2010 MON KEY. All rights reserved.
;; Copyright © 2008, 2009 Lennart Borgman
;; Copyright © 2008 Niels Giesen
;;; ================================================================
;; AUTHOR: Niels Giesen
@tnoda
tnoda / cf.go
Last active August 29, 2015 14:04
cf.go
package main
import (
"bufio"
"errors"
"fmt"
"io"
"os"
"strconv"
)