Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

System.Linq.Enumerable.Repeat method: Explanation for count argument slightly inaccurate (nitpicking) #4012

Copy link
Copy link
Open
@elgonzo

Description

@elgonzo
Issue body actions

I admit, this issue report is on the verge of nitpicking, but nevertheless...

The count argument for the Enumerable.Repeat method currently states:

The number of times to repeat the value in the generated sequence

This is of course incorrect :)
In fact, the value is repeated count-1 times in the generated sequence; when count is being 0 the generated sequence is empty.

A more accurate description for the count argument could perhaps be something like:

The number of times the value occurs in the generated sequence


Github link to the respective line in the documentation source:

<param name="count">The number of times to repeat the value in the generated sequence.</param>

Link to documentation: https://docs.microsoft.com/en-us/dotnet/api/system.linq.enumerable.repeat?view=netstandard-2.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    Pri3Indicates issues/PRs that are low priorityIndicates issues/PRs that are low priorityarea-System.LinquntriagedNew issue has not been triaged by the area ownerNew issue has not been triaged by the area owner

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.