Write an awk program - unix , Computer Engineering

Write an AWK program which takes the following input file and processes it.

$cat data.txt
John Do 111-1111 English 90 Maths 80
Alice Do 222-2222 English 90 Maths 90 Chemistry 93

The input file has first 3 fields fixed as first name, last name, and student id. After the student id, it has a variable number of fields which has a pair of name of a subject and points scored in that subject. Your output should print the full name of the student, number of subjects taken, and his/her average score. The output corresponding the above input file is as follows:

$awk -f avgerage.awk data.txt

John Do: 2 subjects taken, average = 85

Alice Do: 3 subjects taken, average = 91

Posted Date: 3/14/2013 2:07:20 AM | Location : United States







Related Discussions:- Write an awk program - unix , Assignment Help, Ask Question on Write an awk program - unix , Get Answer, Expert's Help, Write an awk program - unix Discussions

Write discussion on Write an awk program - unix
Your posts are moderated
Related Questions
SET SCREEN With SET SCREEN the present screen simply specifies the next screen in the chain , control branches to this next screen  as soon as the current screen has been proce

Display how the value ASCII "MIRIAM" is stored in memory in Big Endian format starting at location 100 hexadecimal. Suppose that each memory location kept two ASCII characters.

What is micro programmed control? Micro programmed control is a scheme in which control signals are formed by a program same to machine language program.

Analysis of Sort_Bitonic(X) The bitonic sorting network needs log n number of phases for performing task of sorting the numbers. The first n-1 phases of circuit can sort two n/

a. Write down the salient difference among conventional T.V. and High Definition TV (HDTV) and also highlight the various benefits of digital representation for video. b. Video

What is assembly language? A complete set of symbolic names and rules for the use of machines comprise a programming language, usually referred to as an assembly language.

Explain about the term Middleware. Middleware is the term frequently used to explain the application or business logic present within an application server. Unfortunately, simi

The Purpose of POINTER phrase is to verify the leftmost position within receiving field where the first transferred character will be kept

Classify computer systems according to capacity. How they are different from computers according to the classification of technology. Provide comparative study also.

Define about classes of object oriented modelling A class is a collection of things, or concepts that have the same properties. Each of these concepts or things is known an obj