I have an F# library that returns an FSharpList to my C# caller.
I would now like my C# caller's code to convert this into a List.
What is the most efficient way to do this in C#?
Thanks.
Easier than I thouglt...
Starting with:
List<double> niceList= new List<double>();
From List
to FSharpList
I did this:
FSharpList<double> niceSharpList = ListModule.OfSeq(niceList);
and to convert back from FSharpList
to List
I did:
List<double> niceList= niceSharpList.ToList();
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With