Write a program to split the contents of a file specified


Problem

1. Write a program to split the contents of a file specified as argument into multiple files so that each file contains at most 10,000 bytes. Name the files foo.1, foo.2, and so forth if foo is the argument.

2. Write a program that uses error checking to perform the following on an existing file foo:

(i) opens foo and then deletes it without closing it;

(ii) reads foo and displays its output;

(iii) opens foo again. After the program has completed execution, check whether foo has actually been deleted. Explain your observations with reference to the behavior of the unlink system call.

Request for Solution File

Ask an Expert for Answer!!
Computer Engineering: Write a program to split the contents of a file specified
Reference No:- TGS02672070

Expected delivery within 24 Hours