|
| 1 | +# Generated by basalt-cli |
| 2 | +# |
| 3 | +# This basic example just includes a custom language and a supported language, |
| 4 | +# two competitors, a host, a single problem, and some sane runner configurations. |
| 5 | +# |
| 6 | +# There are also examples showing how you could instead import pieces for a multi-file config setup. |
| 7 | +# |
| 8 | +# Happy hacking! |
| 9 | + |
| 10 | +port = 8517 |
| 11 | + |
| 12 | +[setup] |
| 13 | +# import = "./setup.toml" |
| 14 | + |
| 15 | +# install = { import = "./install.sh" } |
| 16 | +install = ''' |
| 17 | +dnf install opam |
| 18 | +''' |
| 19 | + |
| 20 | +# init = { import = "./init.sh" } |
| 21 | +init = ''' |
| 22 | +opam init -y |
| 23 | +eval $(opam env) |
| 24 | +''' |
| 25 | + |
| 26 | +[test_runner] |
| 27 | +# import = "./test-runner.toml" |
| 28 | + |
| 29 | +timeout_ms = 60_000 |
| 30 | +trim_output = true |
| 31 | +max_memory = { compile = 128, run = 64 } |
| 32 | +max_file_size = 8192 |
| 33 | + |
| 34 | +[languages] |
| 35 | +python3 = "latest" |
| 36 | +java = "21" |
| 37 | +ocaml = { build = "ocamlc -o out solution.ml", run = "./out", source_file = "solution.ml" } |
| 38 | + |
| 39 | +[[accounts.hosts]] |
| 40 | +name = "host" |
| 41 | +password = "pwd1" |
| 42 | + |
| 43 | +[[accounts.competitors]] |
| 44 | +name = "team1" |
| 45 | +password = "pwd1" |
| 46 | + |
| 47 | +[[accounts.competitors]] |
| 48 | +name = "team2" |
| 49 | +password = "pwd1" |
| 50 | + |
| 51 | +# Specify information about the packet itself |
| 52 | +[packet] |
| 53 | +# import = "./packet.toml" |
| 54 | +title = "{{ name }}" |
| 55 | +preamble = ''' |
| 56 | +This packet includes problems of a difficulty *vastly* |
| 57 | +surpassing the capabilities of the average computer |
| 58 | +science student. Be wary as these problems will |
| 59 | +certainly give you great intellectual trouble. There |
| 60 | +is little hope for anyone without a Ph.D in computer |
| 61 | +science. |
| 62 | +
|
| 63 | +If you decide to attempt these problems anyways, good |
| 64 | +luck. You will be rewarded for swiftness in your answers. |
| 65 | +''' |
| 66 | + |
| 67 | +[[packet.problems]] |
| 68 | +# import = "./problem1.toml" |
| 69 | +title = "Reversing a string" |
| 70 | +description = ''' |
| 71 | +Reversing a string is one of the most *basic* algorithmic |
| 72 | +problems for a beginner computer science student to solve. |
| 73 | +
|
| 74 | +Solve it. |
| 75 | +''' |
| 76 | + |
| 77 | +[[packet.problems.tests]] |
| 78 | +input = "hello" |
| 79 | +output = "olleh" |
| 80 | +visible = true |
| 81 | + |
| 82 | +[[packet.problems.tests]] |
| 83 | +input = "world" |
| 84 | +output = "dlrow" |
| 85 | +visible = true |
| 86 | + |
| 87 | +[[packet.problems.tests]] |
| 88 | +input = "" |
| 89 | +output = "" |
| 90 | + |
| 91 | +[[packet.problems.tests]] |
| 92 | +input = "aa" |
| 93 | +output = "aa" |
| 94 | + |
| 95 | +[[packet.problems.tests]] |
| 96 | +input = "racecar" |
| 97 | +output = "racecar" |
0 commit comments