hi I am trying to write a simple cat program in C but am getting very confused. I thought i knew where to start but I dont. the assignment says: You will be writing a simple version of the program "cat". It must accept as arguments any number fo filenames. Each file's contents should be printed to stdout. Errors go to stderr, including if you cannot open a file. Do not crash if a file is not found, do continue to other files if one is not found. I am confused about where it will be getting files from? and how do i get things to print to stderr?:rolleyes:
If someone would please help me get started I would appreciate it!
Jump to Post
>I am confused about where it will be getting files from?
The program will be executed like this:
$ mycat file1 file2 file3
For the purposes of your assignment, you can assume the following for argc and argv of main:
argc = 4; argv …
All 6 Replies
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, learning, and sharing knowledge.