https://www-k6.thinkcentral.com/content/hsp/math/mathinfocus/common/itools_int_9780547673844_/counters.html