changed output format to specify flag