Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Assignment No. 05 Semester: Spring 2009 CS201: Introduction toProgramming Total

ID: 3612287 • Letter: A

Question

Assignment No. 05
Semester: Spring 2009

CS201: Introduction toProgramming

Total Marks: 20

Due Date:18/06/2009

Instructions

Please read the following instructions carefully beforesubmitting assignment:

It should be clear that your assignment will not get anycredit if:

§        The assignment is submitted after due date.

§        The submitted assignment does not open or file iscorrupt.

§        All types of plagiarism are strictlyprohibited.

Note: You have to upload only.cpp file. Assignment in any other format(extension) will not be accepted. If you will submit codein .doc (Word document) you will get zero marks.

Objective

The objective of this assignment is to provide hands onexperience of using

§         FileHandling in C/C++

Guidelines:

§         Codeshould be properly aligned and well commented.

§         Followc/c++ rules while writing variables names, function names etc

§         Use onlydev-C++ for this assignment.

Assignment

Problem Statement:

          Writing and Reading student data in a file.

Detailed Description:

Write a program in which you have to:

1. Create a text file “Student_info”.

2. Using Code Write the following data in it:

Roll NO   Student Name    Class

101        AliRaza       BS(CS)

102        Usman         MS(CS)

103        Faizan        BS(CS)

104        Rehan         MIT

105        Ahmed         MCS

3. Open file and read data from it and display on thescreen.

        

Sample Output

Student Information

Roll NO   Student Name    Class

101        AliRaza       BS(CS)

102        Usman        MS(CS)

103        Faizan       BS(CS)

104        Rehan         MIT

105        Ahmed         MCS

Deadline

Your assignment must be uploaded/submitted on or before15-06-2009.

Assignment No. 05
Semester: Spring 2009

CS201: Introduction toProgramming

Total Marks: 20

Due Date:18/06/2009

Instructions

Please read the following instructions carefully beforesubmitting assignment:

It should be clear that your assignment will not get anycredit if:

§        The assignment is submitted after due date.

§        The submitted assignment does not open or file iscorrupt.

§        All types of plagiarism are strictlyprohibited.

Note: You have to upload only.cpp file. Assignment in any other format(extension) will not be accepted. If you will submit codein .doc (Word document) you will get zero marks.

Objective

The objective of this assignment is to provide hands onexperience of using

§         FileHandling in C/C++

Guidelines:

§         Codeshould be properly aligned and well commented.

§         Followc/c++ rules while writing variables names, function names etc

§         Use onlydev-C++ for this assignment.

Assignment

Problem Statement:

          Writing and Reading student data in a file.

Detailed Description:

Write a program in which you have to:

1. Create a text file “Student_info”.

2. Using Code Write the following data in it:

Roll NO   Student Name    Class

101        AliRaza       BS(CS)

102        Usman         MS(CS)

103        Faizan        BS(CS)

104        Rehan         MIT

105        Ahmed         MCS

3. Open file and read data from it and display on thescreen.

        

Sample Output

Student Information

Roll NO   Student Name    Class

101        AliRaza       BS(CS)

102        Usman        MS(CS)

103        Faizan       BS(CS)

104        Rehan         MIT

105        Ahmed         MCS

Deadline

Your assignment must be uploaded/submitted on or before15-06-2009.

Explanation / Answer

please rate - thanks #include #include #include using namespace std;    int main()    {char filename[30];     int num,i;     string name,classs,line;     ifstream input;     ofstream output;     coutfilename;   output.open(filename);          //open file   if(output.fail())            //is it ok?        { cout
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote