Use constants instead of magic numbers