mirror of
https://github.com/ivuorinen/cheatsheet-tldr.git
synced 2026-03-06 05:56:46 +00:00
Update cheatsheets
This commit is contained in:
8
tldr/dc
8
tldr/dc
@@ -19,16 +19,16 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
- Calculate an expression with the specified scale:
|
||||
|
||||
`dc --expression='{{10}} k {{5 3 /}} p'`
|
||||
`dc {{[-e|--expression]}} '{{10}} k {{5 3 /}} p'`
|
||||
|
||||
- Calculate 4 times 5 (4 5 *), subtract 17 (17 -), and [p]rint the output:
|
||||
|
||||
`dc --expression='4 5 * 17 - p'`
|
||||
`dc {{[-e|--expression]}} '4 5 * 17 - p'`
|
||||
|
||||
- Specify the number of decimal places to 7 (7 k), calculate 5 divided by -3 (5 _3 /) and [p]rint:
|
||||
|
||||
`dc --expression='7 k 5 _3 / p'`
|
||||
`dc {{[-e|--expression]}} '7 k 5 _3 / p'`
|
||||
|
||||
- Calculate the golden ratio, phi: set number of decimal places to 100 (100 k), square root of 5 (5 v) plus 1 (1 +), divided by 2 (2 /), and [p]rint result:
|
||||
|
||||
`dc --expression='100 k 5 v 1 + 2 / p'`
|
||||
`dc {{[-e|--expression]}} '100 k 5 v 1 + 2 / p'`
|
||||
|
||||
Reference in New Issue
Block a user