Couldn't figure out a way to make a functional fstream

Sorry I am just a beginner at C++! I wanted to print movie tickets which will include name, the movie selected and the movie timeslot! :C But having trouble as my lecturer did not specify how to use it.

Here's a link to download the cpp file
https://www.mediafire.com/?ksvyiaaq52c99q1

Please help or give guidance thank you very much!
closed account (48T7M4Gy)
So what's the story? The cpp file was prepared by you or your lecturer?
Use <cstdlib> instead of <stdlib.h>. You should use the standard C++ libraries.
I wrote the cpp file. I just need to do fstream, creating txt file that indicates the name, movie title and the movie timeslot!
closed account (48T7M4Gy)
http://www.cplusplus.com/doc/tutorial/files/

Try this tutorial. There are simple samples that show you what to do depending on whteher you want to prepare a text file with the movie details, or read the details in from the file.
Topic archived. No new replies allowed.