These are chat archives for Microsoft/visualfsharp

9th
Dec 2015
Miguel de Icaza
@migueldeicaza
Dec 09 2015 01:21
Hey guys
Anyone knows of some cute F# 1-liners with graphics?
Or a 1-liner repo for that matter
Jared Hester
@cloudRoutine
Dec 09 2015 01:43
@migueldeicaza maybe https://github.com/ptrelford/FunSharp ? if you find something better I'd love to know
Jon Wood
@jwood803
Dec 09 2015 14:45
I can try to poke around FSSnip to see if there’s anything there
Lincoln Atkinson
@latkin
Dec 09 2015 16:30
@migueldeicaza [-2. .. 0.002 .. 2.] |> List.map (fun x -> (x, (sqrt (cos x))*(cos (200.*x)) + (sqrt (abs x)) - 0.7*((4.-x**2.)**0.01)) ) |> Chart.Line
image.png
Steffen Forkmann
@forki
Dec 09 2015 16:31
:heart:
Lincoln Atkinson
@latkin
Dec 09 2015 16:40
let r = System.Random() in [for s in "♣♦♥♠" do for r in "A23456789TJQK" -> sprintf "%O%O" r s] |> List.sortBy (fun _ -> r.NextDouble())
val it : string list =
  ["7♣"; "3♣"; "K♦"; "6♥"; "A♥"; "6♣"; "4♣"; "2♠"; "4♠"; "K♥"; "K♠"; "2♥";
   "Q♣"; "5♣"; "8♠"; "8♦"; "5♠"; "8♥"; "T♠"; "J♥"; "A♣"; "7♦"; "7♥"; "J♦";
   "9♣"; "T♣"; "3♦"; "Q♦"; "4♥"; "8♣"; "7♠"; "5♦"; "2♣"; "6♦"; "K♣"; "5♥";
   "A♠"; "6♠"; "9♥"; "J♠"; "3♥"; "T♥"; "9♠"; "2♦"; "J♣"; "3♠"; "T♦"; "Q♥";
   "4♦"; "Q♠"; "9♦"; "A♦"]