We can now count rice grains :). Also some additional functions.