Added blocks array, function to draw it, function to swap bits in values. Fixed min and max segments count. Added random blocks generation. Fixed drawBlock function. Added function to shift blocks.