Skip to content
This repository has been archived by the owner on Dec 11, 2020. It is now read-only.

docs: Clarify that randomElements() does not repeat input elements #848

Merged
merged 1 commit into from
Mar 10, 2016

Conversation

sustmi
Copy link
Contributor

@sustmi sustmi commented Mar 3, 2016

It was not clear for me whether randomElements() repeats input elements or not until I looked into the implementation.

@@ -156,7 +156,7 @@ public static function randomAscii()
}

/**
* Returns random elements from a provided array
* Returns random elements from a provided array (not repeating input indices)
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't understand your comment

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What about this?

Returns randomly ordered subsequence of $count elements from a provided array

I want for the other users to be clear that the function does not repeat input elements. The current comment does not say it.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok

@sustmi sustmi force-pushed the docs-clarify-random-elements branch from 4c6f71b to 7978ddc Compare March 9, 2016 19:10
@sustmi
Copy link
Contributor Author

sustmi commented Mar 9, 2016

I updated the pull request with the new sentence.

fzaninotto added a commit that referenced this pull request Mar 10, 2016
docs: Clarify that randomElements() does not repeat input elements
@fzaninotto fzaninotto merged commit 588da2f into fzaninotto:master Mar 10, 2016
@fzaninotto
Copy link
Owner

Thanks!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants