Arranging Balls into Boxes

Initializing live version
Download to Desktop

Requires a Wolfram Notebook System

Interact on desktop, mobile and cloud with the free Wolfram Player or other Wolfram Language products.

This Demonstration provides the answers to a variety of questions of the type, In how many ways can balls be placed into boxes? You can vary the number of balls and boxes. Options include distinguishable or indistinguishable balls, distinguishable or indistinguishable boxes, and whether or not empty boxes are permitted.

Contributed by: Marc Brodie (February 2018)
(Wheeling Jesuit University)
Open content licensed under CC BY-NC-SA



Notation follows Martin's text [1]. In particular, stands for the number of integer partitions of into exactly parts.


[1] G. E. Martin, Counting: The Art of Enumerative Combinatorics, New York: Springer-Verlag, 2001.

Feedback (field required)
Email (field required) Name
Occupation Organization
Note: Your message & contact information may be shared with the author of any specific Demonstration for which you give feedback.