Welcome to mirror list, hosted at ThFree Co, Russian Federation.

code.md « examples « content « exampleSite - github.com/mdashx/basicwebtheme.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 4cede28e51d0b8c675cb8c3bfcb8b337b9ee8cf0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
{
    "title": "Code blocks",
    "layout": "standalone"
}

A code block:

```
(defun triangle-recursively (number)
  "Return the sum of the numbers 1 through NUMBER inclusive.
Uses recursion."
  (if (= number 1)                    ; do-again-test
      1                               ; then-part
    (+ number                         ; else-part
       (triangle-recursively          ; recursive call
        (1- number)))))               ; next-step-expression

(triangle-recursively 7)
```