Use done insstead of while True