I was making an app, that takes input and writes it in a csv file.
But when I run, it just exits.
Script,
But when I run, it just exits.
Script,
from tkinter import* import time import csv import os.path import sys if not os.path.exists("timetable.csv"): #run start up script print("Cache was Deleted!\nCreating new Cache") time.sleep(3) with open ("timetable.csv", "w") as timetable : fieldnames = ["From time", "To Time", "Thing To Do"] csv_writer = csv.DictWriter(timetable, fieldnames = fieldnames, delimiter = ",") csv_writer.writeheader() how_many_things = input("How many things are there?\n") while how_many_things > 1: from_time = input(how_many_things + "Please enter from time.\n") to_time = input(how_many_things + "Please enter to time.\n") thing_done = input(how_many_things + "Please enter thing to do.\n") how_many_things -= 1 csv_writer.writerow([from_time, to_time, thing_done]) print("Cache Made!") input()Any ways to solve this problem?