I have a .txt file in my project directory that I made and populated with data.
directory structure looks like:
/Users/asd/ClionProjects/ProjectWithT
if inputFile.is_open() always returns false, inputFile.open("twoday.txt"); is not opening the file correctly, presumably because it can't find "twoday.txt"
Try setting an explicit path like "c:/path/twoday.txt" or "/path/twoday.txt" if you're using Linux. You could also try writing a file instead to see where it shows up, or something more exotic to return the current path.