This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This random game idea generator was a collaboration between David O'Toole (dto) | |
and myself (Tommy Ettinger). The generator is a Clojure program that is available | |
to fork and tweak at http://ideone.com/0MG8ED . |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defn diff [l1 l2] | |
(let [a (group-by identity l1) | |
b (group-by identity l2)] | |
(mapcat #(repeat | |
(- | |
(count (second %)) | |
(count (get b (key %)))) | |
(key %)) | |
a))) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns pixmappery.core | |
(:require [play-clj.core :refer :all] | |
[play-clj.entities :as e] | |
[play-clj.g2d :refer :all] | |
[play-clj.ui :refer :all]) | |
(:import [com.badlogic.gdx.graphics.g2d Batch SpriteBatch] | |
[com.badlogic.gdx.graphics.glutils ShaderProgram])) | |
(defn vert [] "attribute vec4 a_position; | |
attribute vec4 a_color; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns clj-ebay.main | |
(:require [overtone.at-at :as schedule] | |
[clj-ebay.core] | |
[clj-ebay.finding :as finder]) | |
(:gen-class)) | |
(def my-pool (schedule/mk-pool)) | |
(defn search-from-ebay | |
"comment" | |
[searched-key max-price] | |
(let [result (finder/find-items-advanced {:entries-per-page "1", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class AndroidMiniFormatter implements MiniFormatter { | |
public static String format(final String formatString, final Object... args) { | |
return String.format(formatString, args); | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 | |
stack: [1] //data, integer 1 | |
1 + | |
stack: [(+ 1 _)] //curried function that will await an argument and add 1 to it | |
1 + 2 | |
stack: [3] //argument has been supplied to an awaiting function, function is evaluated | |
//with full set of args | |
1 + 2 * | |
stack: [(* 3 _)] //another curried function that will await an argument and multiply it by 3 | |
1 + 2 * [# |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
┌───────────────┐ | |
┌─┘ . . . . . . . └─┐ | |
┌───┬───┐ ┌─────┐ ┌───┐ ┌─────┐ │ . . . . . . . . . │ | |
┌───────┘ ~ │ . └─┬─┘ . . └─┐ ┌───────────┘ . └─────┘ . . └───┐ │ . . . . . . . . . │ | |
┌─┘ ~ ~ ~ ~ ~ , . . │ . . |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
┌───────────────────────────┐ | |
┌─┘ . . . . . . . . . . ^ . . └─┐ ┌───┐ ┌─────────────────┐ | |
│ . . . . . . . . . . . . . . . │ ┌───────┘ . └───────┐ │ . . . . . . . . │ | |
└─┐ . . . . . . . . . ^ . . . ┌─┘ ┌─┘ . . . . . . . . . └─┐ │ . . . . . . . . │ | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
┌───────┬───────────────────────┐ ┌───────────────────────┐ | |
┌─┘ . . . │ . . . . . . . . . . . └─┐ │ . . . . > . . . . . . │ | |
│ . . . . . . . . . . . . . . . . . └─┐ │ . . . . . . . . . . . │ | |
│ . . . . . . . . . . . . . . . . . > │ │ . . . . . . . . . . . │ | |