Stacks and heaps of coins