Threads and files update your solution to exercise which


Question: Threads and Files. Update your solution to Exercise which obtains a byte value and a file name, displaying the number of times that byte appears in the file. Let's suppose this is a really big file. Multiple readers in a file is acceptable, so create multiple threads that count in different parts of the file so that each thread is responsible for a certain part of the file. Collate the data from each thread and provide the summed-up result. Use your time it() code to time both the single threaded version and your new multithreaded version and say something about the performance improvement.

Exercise: Generating Files. Create a sister program to the previous problem. Create a binary data file with random bytes, but one particular byte will appear in that file a set number of times. Obtain the following three values: (1) a byte value (0-255), (2) the number of times that byte should appear in the data file, and (3) the total number of bytes that make up the data file. Your job is to create that file, randomly scatter the request byte across the file, and to ensure that there are no duplicates and that the file contains exactly the number of occurrences that byte was requested for, and that the resulting data file is exactly the size requested.

Request for Solution File

Ask an Expert for Answer!!
Basic Computer Science: Threads and files update your solution to exercise which
Reference No:- TGS02581014

Expected delivery within 24 Hours