#!/usr/bin/env python3 import time #merge dir w schreibt neu a fügt hinzu :) with open("Textdatei.txt", "a") as write_input : while True: eingabe = input("Gib etwas ein : ") if eingabe == "" : break print(time.strftime('%Y-%m-%d %H:%M:%S') + " input {my_input}".format(my_input=eingabe), file=write_input)