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 algo.stack) | |
(defn make-stack [] {:first nil}) | |
(defn is-empty? [stack] (nil? (:first stack))) | |
(defn stack-push [stack item] | |
(let [previous (:first stack)] | |
{:first | |
{:item item :next previous}})) |
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
export LANGUAGE=en_US.UTF-8 | |
export LANG=en_US.UTF-8 | |
export LC_ALL=en_US.UTF-8 | |
locale-gen en_US.UTF-8 | |
dpkg-reconfigure locales |
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
SELECT CAST(date_part('year', date) AS varchar(4)) || '-' || CAST(date_part('month', date) AS varchar(2)) AS month, SUM(amount) | |
FROM withdrawals | |
WHERE some_predicate() | |
GROUP BY month | |
ORDER BY month; |
NewerOlder