Counts

Counts[list]

gives an association whose keys are the distinct elements of list, and whose values give the number of times those elements appear in list.

Details

  • Counts[list] gives an association whose keys are in the same order as they first occur as elements of list.

Examples

Basic Examples  (2)

Wolfram Research (2014), Counts, Wolfram Language function, https://reference.wolfram.com/language/ref/Counts.html.

Text

Wolfram Research (2014), Counts, Wolfram Language function, https://reference.wolfram.com/language/ref/Counts.html.

CMS

Wolfram Language. 2014. "Counts." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/Counts.html.

APA

Wolfram Language. (2014). Counts. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/Counts.html

BibTeX

@misc{reference.wolfram_2023_counts, author="Wolfram Research", title="{Counts}", year="2014", howpublished="\url{https://reference.wolfram.com/language/ref/Counts.html}", note=[Accessed: 28-March-2024 ]}

BibLaTeX

@online{reference.wolfram_2023_counts, organization={Wolfram Research}, title={Counts}, year={2014}, url={https://reference.wolfram.com/language/ref/Counts.html}, note=[Accessed: 28-March-2024 ]}