Skip to content
This repository has been archived by the owner on Nov 26, 2024. It is now read-only.

Update seq.mapi['t,'u]-function-[fsharp].md #344

Open
wants to merge 1 commit into
base: live
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions docs/conceptual/seq.mapi['t,'u]-function-[fsharp].md
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,21 @@ The result sequence.
## Remarks
This function is named `MapIndexed` in compiled assemblies. If you are accessing the function from a .NET language other than F#, or through reflection, use this name.

## Example
```
let text = "hello"
Seq.mapi (fun i c -> sprintf "%d - %c" i c) text |> Seq.iter (fun s -> printfn "%s" s)
```

**Output**

```
0 - h
1 - e
2 - l
3 - l
4 - o
```

## Platforms
Windows 8, Windows 7, Windows Server 2012, Windows Server 2008 R2
Expand Down