TODO : | [0] - Counter for record_type | [1] - sorted dictionary | [2] - readfile in parts | [3] - code optimize