Default value should be set before loop