codingteam's submission for the ICFP Contest 2023.
News: this year, we won the judges' prize:
Finally, the judges prize was attributed to team Codingteam, whose writeup we really enjoyed reading (and the mix of F# and Fortran in their solution was both surprising and fun to see)
https://icfpcontest2023.github.io/
- July 7th, 12:00 UTC (noon) to July 10th, 12:00 UTC 2023
- @Akon32
- @ForNeVeR: link to report in English
- @Minoru: link to report in Russian
- @foxtran
- @gsomix
- @portnov
Latest available rating: we've had 51'st place with a score of 97,433,577,912.
All the credentials and tokens to access the contest resources are stored in a pinned message in our Telegram chat and in the conference topic in the XMPP chat.
⚠ Please save the access token to file token.txt
in the solution directory.
.NET SDK 7.0 is required. Get it for your platform at https://dotnet.microsoft.com/en-us/download (binary installers are available as well as packages for various Linux distributions).
- https://thomasbandt.com/fsharp-introduction
- https://learnxinyminutes.com/docs/fsharp/
- https://fsharp.github.io/fsharp-core-docs/
- Just ask @ForNeVeR or @gsomix
$ dotnet build
$ dotnet run --project Icfpc2023 -- [arguments here…]
# or, alternately:
$ cd Icfpc2023 && dotnet run -- [arguments here…]
$ dotnet run --project Icfpc2023.Visualizer [-- <problemNumber>]
# or, alternately:
$ cd Icfpc2023.Visualizer && dotnet run [-- <problemNumber>]
Download all problems:
$ dotnet run --project Icfpc2023 -- download all
Upload all solutions from the solutions/
directory:
$ dotnet run --project Icfpc2023 -- upload all
Solve problem 1 using dummy solver:
$ dotnet run --project Icfpc2023 -- solve 1 dummy
Solve all problems using dummy solver:
$ dotnet run --project Icfpc2023 -- solve all dummy
Solve all problems using non-deterministic solvers and save solutions if they improve upon the existing ones:
$ dotnet run --project Icfpc2023 -- solve all best-nondeterministic --preserve-best
It makes sense to re-run that command from time to time because non-deterministic solvers have a chance of finding a better solution.
Solve problem 1 using all solvers and picking the best solution:
$ dotnet run --project Icfpc2023 -- solve all best
Solve problem 1 using dummy solver and preserve best solution if already exists:
$ dotnet run --project Icfpc2023 -- solve 1 dummy --preserve-best
Calculate score for solution 1 on problem 1:
$ dotnet run --project Icfpc2023 -- score 1
Improve existing solution of problem 1 using lambda solver:
$ dotnet run --project Icfpc2023 -- improve 1 lambda
Improve existing solution of problem 1 using lambda solver, but preserve best solution:
$ dotnet run --project Icfpc2023 -- improve 1 lambda --preserve-best
Lambda score showcase (I dunno, see PR #4 for details):
$ dotnet run --project Icfpc2023 -- lambdaScore
Convert Problem+Solutions to INI:
$ dotnet run --project Icfpc2023 -- convertini <all|problemId>
Import solutions from INI:
$ dotnet run --project Icfpc2023 -- vulpes all # no other options supported, sorry!
Download first 3 problems:
$ dotnet run --project Icfpc2023 -- download 3
$ dotnet test
See https://dotnet.microsoft.com/en-us/languages/fsharp/tools for the main options.
Fee free to use editor of choice, but the easiest tools to get started are:
-
Visual Studio (Windows-only)
- Community Edition is free and should be okay for this project
- Open
Infpc2023.sln
and then press the Run button
-
Visual Studio Code with Ionide extension (cross-platform)
- Totally free
- Open the solution folder (the one with the
.sln
file), install the Ionide extension, and then use the Run and Debug tool window to execute the project
-
JetBrains Rider (cross-platform)
- Commercial
- Free EAP and trial builds are available and are okay to use for this project (I, @ForNeVeR, use EAP myself)
- Open the
.sln
file and then hit the green Run button to get started
Other viable options are Vim, Emacs, and any editor with LSP support via FsAutoComplete.