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
var finalCountDown = (function(){ | |
var end = new Date('01/01/2014 00:00:00'), | |
timer, | |
second = 1000, | |
minute = second * 60, | |
hour = minute * 60, | |
day = hour * 24; | |
return function(textSetter){ | |
timer = setInterval(function() { |
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
html, body, div, span, applet, object, iframe, | |
h1, h2, h3, h4, h5, h6, p, blockquote, pre, | |
a, abbr, acronym, address, big, cite, code, | |
del, dfn, em, img, ins, kbd, q, s, samp, | |
small, strike, strong, sub, sup, tt, var, | |
b, u, i, center, | |
dl, dt, dd, ol, ul, li, | |
fieldset, form, label, legend, | |
table, caption, tbody, tfoot, thead, tr, th, td, | |
article, aside, canvas, details, embed, |
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
Show hidden characters
{ | |
// JSHint Default Configuration File (as on JSHint website) | |
// See http://jshint.com/docs/ for more details | |
"maxerr" : 50, // {int} Maximum error before stopping | |
// Enforcing | |
"bitwise" : true, // true: Prohibit bitwise operators (&, |, ^, etc.) | |
"camelcase" : false, // true: Identifiers must be in camelCase | |
"curly" : true, // true: Require {} for every new block or scope |
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 logical-db.core | |
(:require [clojure.core.logic :as l] | |
[clojure.core.logic.protocols :refer [walk]] | |
[clojure.core.logic.pldb :as db])) | |
; [org.clojure/clojure "1.8.0"] | |
; [org.clojure/core.logic "0.8.10"] | |
(def db { :city->zip {"City1" [1 2 3 4] "City2" [5 6]} |
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 markov-text.core | |
(:require [clojure.string :as str])) | |
(defn spliter [str] | |
(mapv str/lower-case (str/split str #"\s"))) | |
(defn markov-chain [n-gram-size words] | |
(loop [m-chain {} | |
words words] |
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
{ | |
;; Layers you wish to have active | |
;; To get a list of all available layers, check github.com/dvcrn/proton/tree/master/src/cljs/proton/layers | |
:layers | |
[ | |
;; ----------------------------------- | |
;; core layer. Don't remove. | |
;; ----------------------------------- | |
:core |
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
xrandr --newmode 1920x1080_60.00 173.00 1920 2048 2248 2576 1080 1083 1088 1120 -hsync +vsync | |
xrandr --addmode eDP1 1920x1080_60.00 | |
xrandr --output eDP1 --mode 1920x1080_60.00 --rate 60 |
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 test.html | |
(:require [clojure.spec :as s] | |
[clojure.string :as string]) | |
(:require-macros [cljs.spec :as s])) | |
(def non-closing-elements | |
#{:area :base :br :col :command | |
:embed :hr :img :input :link | |
:meta :keygen :param :source | |
:track :wbr}) |
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 fizzbuzz.core) | |
(defn str-max [a b] | |
(if (<= (compare a b) 0) b a)) | |
(def fizzes (cycle ["" "" "fizz"])) | |
(def buzzes (cycle ["" "" "" "" "buzz"])) | |
(def numbers (sequence (comp (map inc) (map str)) (range))) | |
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
(into [] (partition-by #(not= % :spliter)) [1 2 3 4 :spliter 4 3 2 1 :spliter]) | |
;; ^^^^ this is like the base case. output is [[1 2 3 4] [:spliter] [4 3 2 1] [:spliter]] | |
(def in (chan)) | |
(def out (chan 1 (partition-by #(not= % :spliter)))) | |
(pipe in out) |
OlderNewer