Flush stdout after printing prompt so getline is on same line