docs icon indicating copy to clipboard operation
docs copied to clipboard

Array.concat has superfluous output description

Open draptik opened this issue 1 year ago • 0 comments

The final block in the Array.concat section (just before the Array.filter section) appears to be a copy & paste mistake.

[Array.concat](https://fsharp.github.io/fsharp-core-docs/reference/fsharp-collections-arraymodule.html#concat) takes a sequence of arrays and combines them into a single array. The following code demonstrates Array.concat.

F#

Copy
Array.concat [ [|0..3|] ; [|4|] ]
//output [|0; 1; 2; 3; 4|]

Array.concat [| [|0..3|] ; [|4|] |]
//output [|0; 1; 2; 3; 4|]
The output of the preceding code is as follows.

Console

Copy
[|(1, 1, 1); (1, 2, 2); (1, 3, 3); (2, 1, 2); (2, 2, 4); (2, 3, 6); (3, 1, 3);
(3, 2, 6); (3, 3, 9)|]

The paragraph

The output of the preceding code is as follows.

Console

Copy
[|(1, 1, 1); (1, 2, 2); (1, 3, 3); (2, 1, 2); (2, 2, 4); (2, 3, 6); (3, 1, 3);
(3, 2, 6); (3, 3, 9)|]

seems wrong here. I think it should be deleted.

Or did I miss something obvious?


Document Details

Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

  • ID: 6cda87e0-998a-086f-f5ed-2290d7a97966
  • Version Independent ID: 45152c64-0643-3c5a-93cb-a2f689170887
  • Content: Arrays in F#
  • Content Source: docs/fsharp/language-reference/arrays.md
  • Product: dotnet-fsharp
  • GitHub Login: @cartermp
  • Microsoft Alias: dotnetcontent

draptik avatar Jul 29 '22 18:07 draptik