Takes a list of (quantity/amount and price/rate) as decimals, and gives a weighted average
0 people like thisPosted: 2 days ago by Tuomas Hietanen
Example of shaping an anonymous-object-as-JSON structure for an Azure dashboard using strong typing and minimal code using Farmer F# https://compositionalit.github.io/farmer/
0 people like thisPosted: 2 days ago by Tuomas Hietanen
A functional wrapper around MailboxProcessor that simplifies agent-based concurrency, adds error handling via events, and provides convenience functions to avoid common pitfalls when working with asynchronous message processing in F#.
0 people like thisPosted: 1 month ago by halcwb
Timestamp: Time format in ISO 8601 with timezone. YYYYMMDDhhmmssffff+zzzz For example 2011-05-17 19:01:10.000 -0200 would be: 20110517190110000-0200
0 people like thisPosted: 3 months ago by Tuomas Hietanen
Word guessing game using ASCII art.
3 people like thisPosted: 3 months ago by Phillip Trelford
Generate random hex-string and calculate base58encode. I made these for some initial BTC-testing, but didn't test too much... seems to work, but would need some unit-tests... :-) Feel free to update or add new versions.
2 people like thisPosted: 4 months ago by Tuomas Hietanen
Demonstrates how to implement the dynamic operator (?) using .NET Reflection. The implementation supports calling constructors, propreties and methods using simple overload resolution (based on parameter count). It handles instance as well as static members.
73 people like thisPosted: 14 years ago by Tomas Petricek
The following sample wants to make sure the person’s age is between 18 and 65, weight is no more than 200 and tall enough (>120).
83 people like thisPosted: 14 years ago by Tao Liu
This is to demonstrate that: (1) there are many ways to solve the same problems; (2) operators can be grouped together into data structures and act as data; (3) you can have fun in F# in many ways.
57 people like thisPosted: 14 years ago by Dmitry Soshnikov
This is to demonstrate that: (1) there are many ways to solve the same problems; (2) operators can be grouped together into data structures and act as data; (3) you can have fun in F# in many ways.
57 people like thisPosted: 14 years ago by Dmitry Soshnikov
Continuations provide a means whereby heap space can be traded for stack depth (heap space being generally more plentiful than stack depth). They are especially useful where tail recursion is not possible. Here are a couple of simple continuation examples that can be extended to cover more complex scenarios.
100 people like thisPosted: 14 years ago by Neil Carrier
I use this basic template when writing .fsx files that I might want to compile. It adjusts the difference in command line/entrypoint handling between a script and a compiled assembly. This example shows the details for a WPF script — replace the #r's and/or remove the STAThread for a WinForms or Console script.
124 people like thisPosted: 14 years ago by Blake Coverett
lists (15) kata (17) json (16) html (16) collections (16) tutorial (17) computation expression (15) parsing (28) sequences (48) seq (54) wpf (20) sequence (32) agent (20) list (56) generic programming (17) computation builder (17) web (29) algorithms (26) reflection (19) dsl (23)
Tomas Petricek (150) Nick Palladinos (66) Rick Minerich (15) nagat01 (19) Tao Liu (17) fholm (26) Eirik Tsarpalis (89) Ryan Riley (25) Antonio Cisternino (8) Ankur Dhama (20) Tuomas Hietanen (78) Faisal Waris (37) Brian Berns (9) David Klein (16) Samuel Bosch (12) Fabio Galuppo (14) Gauthier Segay (11) devshorts (11) Kit Eason (51) Carsten König (10)
Database contains 3203 snippets out of which 1717 is public.