Refactor variables
Fix text format