Case Studies

The reference chapters explain one function at a time. A case study does the opposite: it takes a small but complete task and solves it end to end, so you can see how the pieces of Funcky fit together, which one to reach for at which point, and what the resulting code looks like next to the conventional version.

Each study is self-contained and comes with the full program, which compiles against the current release.

Case studyTaskFeatures
Simplify if null by using an OptionRefactor a chain of null checks step by stepOption, FromNullable, Select, AndThen, GetOrElse
Formatting a calendar pageLay out a yearly calendar as a streaming pipelineSequence.Successors, AdjacentGroupBy, Chunk, Transpose, JoinToString, Curry
Importing a CSV fileParse and validate records, report or reject bad linesParseOrNone, Either, LINQ over monads, Partition, Sequence, WithIndex, MaxByOrNone, Pairwise, InclusiveScan

If you have a task that you solved with Funcky and that shows an aspect none of these cover, a new case study is a welcome contribution.