mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
enum.c (enum_tally): better example in rdoc
This commit is contained in:
parent
e72769ef81
commit
c04ef141d2
1 changed files with 1 additions and 2 deletions
3
enum.c
3
enum.c
|
@ -1009,8 +1009,7 @@ tally_i(RB_BLOCK_CALL_FUNC_ARGLIST(i, hash))
|
||||||
* elements and the values are numbers of elements in the collection
|
* elements and the values are numbers of elements in the collection
|
||||||
* that correspond to the key.
|
* that correspond to the key.
|
||||||
*
|
*
|
||||||
* (1..6).tally #=> {1=>1, 2=>1, 3=>1, 4=>1, 5=>1, 6=>1}
|
* ["a", "b", "c", "b"].tally #=> {"a"=>1, "b"=>2, "c"=>1}
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
static VALUE
|
static VALUE
|
||||||
|
|
Loading…
Reference in a new issue