Apply awk, grep, sed filters

Completed Posted Jun 29, 2002 Paid on delivery
Completed Paid on delivery

Use any of the types of filters such as awk, grep, or sed to design a new command/script, called viewprog, which allows the on-screen viewing of a range of lines of a file passed in as an argument to it. The command should be invoked as follows: viewprog num1 num2 fileA where num1 …. the number of the first of the lines you want to view num2 …. the number of the last line you want to view fileA …. denotes the file whose contents you want to view Since a screen displays at most 24 lines, the range of lines to be displayed should not exceed 20, in order to allow space for a message line at the bottom of the screen, plus some spacing. If num2 ??" num1 > 20, only the first 20 lines should be displayed and a one line message at the bottom of the screen should alert the user that there are more lines to be viewed and the space bar should be depressed to see the next 20 lines (if any). If num1 and num2 are in reverse order, so that num2 < num1 , a message should be displayed on the screen, requesting that the command be reentered and that the beginning line number be less than that of the last line. Test the command you have designed and ascertain that it functions correctly with any range of lines, to include the complete file from the beginning to end, and partial ranges, with num1 = 1, that is the beginning line, or num2=$, where the symbol $ denotes the last line of the file.

## Deliverables

Complete and fully-functional working program(s) in executable form as well as complete source code of all work done. Complete copyrights to all work purchased.

## Platform

Linux 7.2 using the Bourne Shell

Engineering Linux MySQL PHP Software Architecture Software Testing UNIX

Project ID: #2858049

About the project

4 proposals Remote project Active Jun 30, 2002

Awarded to:

cpandz

See private message.

$1 USD in 14 days
(12 Reviews)
1.9

4 freelancers are bidding on average $5 for this job

jasontepoorten

See private message.

$6.8 USD in 14 days
(27 Reviews)
5.0
greenlad

See private message.

$6.8 USD in 14 days
(14 Reviews)
3.4
vw468826vw

See private message.

$4.25 USD in 14 days
(3 Reviews)
2.4