All problems

Checking for Empty Clusters

easyPythonK-Means Clustering

After every round Wexford Couriers runs a sanity check on the result. The group of addresses booked to one site is called that site's cluster, and a site whose cluster came out with nothing in it is a genuine problem: it has no addresses to take a balance point from, so the next round cannot place it anywhere, and the run has quietly lost a locker without saying so. The counts arrive in site order and the check has to see all of them, first to last. A site with a single address is thin, but it is not the fault being looked for.

Task: Print the result of the sanity check.

Input

The first line holds one integer n, the number of sites. The second line holds n counts separated by single spaces: how many addresses each site's cluster finished the round with.

Output

One line: has empty cluster if any site's count is exactly zero, or all clusters populated if not one of them is.

Example:

Input:
3
5 0 3

Output:
has empty cluster

Sign in to solve this problem

Reading problems is free for everyone — solving them (Run, Submit, and tracking what you've solved) needs an account.

Sign in

Discussion

Sign in to join the discussion — reading is open to everyone.

Loading comments…