a simple tool for code scale counter