File: what.tr

package info (click to toggle)
turing 0.11-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 10,340 kB
  • sloc: python: 106,582; xml: 101; makefile: 53; sh: 29
file content (23 lines) | stat: -rw-r--r-- 894 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
BlockStmt([
            AssignStmt(parse("i"), parse("42")),
            ForStmt("i", parse("1"), parse("10"), [
                IfStmt(parse("1"), [
                    IfStmt(parse("i % 2"), [
                        ContinueStmt()
                    ]),
                    IfStmt(parse("i > 5"), [
                        FuncStmt("fibo", ["n"], [
                            IfStmt(parse("n <= 1"), [
                                ReturnStmt(parse("n"))
                            ]),
                            ReturnStmt(parse("fibo(n-1)+fibo(n-2)"))
                        ]),
                        DisplayStmt(parse("map(fibo, [5, 7, 9])")),
                        DisplayStmt(parse("i")),
                        BreakStmt()
                    ]),
                    DisplayStmt(parse("i")),
                ])
            ]),
            DisplayStmt(parse("i"))
        ])