Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Does F# has special syntax for Range and Index types?

Tags:

f#

In C# we can use start..end or start..^fromEnd syntax for creating Range value.

In F# we can create enumerable ranges with {start..stop} or {start..step..stop} which are similar to what is returned by Enumerable.Range.

But is there any special syntax for defining ranges and indices?

like image 403
Pavel Voronin Avatar asked Oct 25 '25 03:10

Pavel Voronin


1 Answers

This is supported (to a certain extent) in F# 5.0 preview. https://devblogs.microsoft.com/dotnet/announcing-f-5-preview-1/

like image 123
s952163 Avatar answered Oct 26 '25 20:10

s952163