C++ and Perl homework help

Ukończone Opublikowano Oct 7, 2001 Płatność przy odbiorze
Ukończone Płatność przy odbiorze

I need someone to write some simple C++ and Perl programs as the deliverables describes. These programs will need to compile and run in an Unix environment.

## Deliverables

Complete and fully-functional working program(s) in executable form as well as complete source code of all work done. !!LOOK BELOW!! Write a program (in C/C++ or perl) to simulate the busy-wait process of an I/O device (as demonstrated in class). - The program checks to see if there is a file called "busy". If there is one, it prints a message "device is busy" and then wait. - If there is no "busy" file (either at the start of the program or after waiting for a while), the program prints a message "starting I/O operation", creates a file called "busy" (so that no other program can start another I/O operation). - The program then waits until a file "done" appears. It then prints a message "I/O operation is completed", and deletes both the "busy" and "done" file. Write 3 C/C++ programs to print 5000 lines of the form This is output line number 1. This is output line number 2. .... (1) to stdout, (2) to a file called "output", (3) to /dev/null. In each case, use "gettimeofday" to find the time needed for each of the three programs to complete the output. Can you explain the outcome? Write a perl program "type" that does the following: (1) type FILE - prints the entire content of FILE to stdout. (2) type FILE 9 - prints the first 9 lines of FILE (3) type FILE 9 20 - prints lines 9 to 20 (inclusive) of FILE (4) type FILE 9 end - prints lines 9 to end of FILE (5) type FILE -9 - prints last 9 lines of FILE (5) is probably the hardest. Hint: There is more than one way to solve the problem. Some Unix commands may help, such as "wc" or "tail" (use "man" to find out what these commands do).

## Deadline information

These programs and others that I will post will all have deadlines of Fridays by 10pm Central Standard Time.

Programowanie C Inżynieria MySQL Perl PHP Architektura oprogramowania Testowanie oprogramowania

Numer ID Projektu: #2828761

O projekcie

2 ofert Zdalny projekt Aktywny Oct 7, 2001

Przyznany użytkownikowi:

vw132761vw

See private message.

$46.75 USD w ciągu 14 dni
(33 ocen)
4.2

2 freelancerów złożyło ofertę za $45 w tym projekcie

poojal80

See private message.

$42.5 USD w ciągu 14 dni
(1 Ocena)
0.7