- You can store a price in a floating point variable.
- All currencies are subdivided in 1/100th units (like US dollar/cents, euro/eurocents etc.).
- All currencies are subdivided in decimal units (like dinar/fils)
- All currencies currently in circulation are subdivided in decimal units. (to exclude shillings, pennies) (counter-example: MGA)
- All currencies are subdivided. (counter-examples: KRW, COP, JPY... Or subdivisions can be deprecated.)
- Prices can't have more precision than the smaller sub-unit of the currency. (e.g. gas prices)
- For any currency you can have a price of 1. (ZWL)
- Every country has its own currency. (EUR is the best example, but also Franc CFA, etc.)
* g o a t s e x * g o a t s e x * g o a t s e x * | |
g g | |
o / \ \ / \ o | |
a| | \ | | a | |
t| `. | | : t | |
s` | | \| | s | |
e \ | / / \\\ --__ \\ : e | |
x \ \/ _--~~ ~--__| \ | x | |
* \ \_-~ ~-_\ | * | |
g \_ \ _.--------.______\| | g |
FWIW: I (@rondy) am not the creator of the content shared here, which is an excerpt from Edmond Lau's book. I simply copied and pasted it from another location and saved it as a personal note, before it gained popularity on news.ycombinator.com. Unfortunately, I cannot recall the exact origin of the original source, nor was I able to find the author's name, so I am can't provide the appropriate credits.
- By Edmond Lau
- Highly Recommended 👍
- http://www.theeffectiveengineer.com/
A list of commonly asked questions, design decisions, reasons why Clojure is the way it is as they were answered directly by Rich (even when from many years ago, those answers are pretty much valid today!). Feel free to point friends and colleagues here next time they ask (again). Answers are pasted verbatim (I've made small adjustments for readibility, but never changed a sentence) from mailing lists, articles, chats.
How to use:
- The link in the table of content jumps at the copy of the answer on this page.
- The link on the answer itself points back at the original post.
I made a documentation generator that cashes in on Clojure's dynamism. See the play-cljs docs (a ClojureScript game library) for an example of its output.
Like many of you, I've often wondered what my final regret will be on my deathbed. My best guess came to me in a dream recently. I was walking across the charred earth of an apocalyptic future world, maneuvering around the remains of the less fortunate. I was startled to find a young girl, barely holding onto her life. She murmured something to me. I asked her to repeat it, and she said more loudly: "I...wish your Clojure projects didn't have such crappy documentation."
;;;; mem-usage.lisp | |
;;; MEM-USAGE returns memory used by Lisp image in a plist. | |
;;; MEM-USED prints memory allocated while running the given forms. | |
;;; Works on SBCL, CMUCL, CCL and CLISP. | |
;;; Relies on internal APIs (the ones that ROOM uses). Can break at any time. | |
(defpackage #:mem-usage | |
(:use #:cl) | |
(:export #:mem-usage #:mem-used)) |
Blog 2019/1/25
<- previous | index | next ->
Browsing solutions is a great way to quickly familiarize yourself with a new language!
Blog 2019/1/25
<- previous | index | next ->
Browsing solutions to the same problem is a great way to compare languages!
" Standard shape values when fail to retrieve a global variable. | |
let s:standard_width = 30 | |
let s:standard_height = 10 | |
" List of all windows, which should have a fixed size and/or position. | |
let g:layout_fixed_windows = [ | |
\ { | |
\ 'buffer_name': 'Scratch', |