Define vars outside of the loop