We are here with you hands in hands to facilitate your learning & don't appreciate the idea of copying or replicating solutions. Read More>>

Looking For Something at vustudents.ning.com? Click Here to Search

www.bit.ly/vucodes

+ Link For Assignments, GDBs & Online Quizzes Solution

www.bit.ly/papersvu

+ Link For Past Papers, Solved MCQs, Short Notes & More

Assignment No. 01
Semester: Spring 2016
Object Oriented Programming – CS304
Total Marks: 20

Due Date: May 19, 2016

Objectives:
To get a hands on experience in creating and using a class according to requirements.
Instructions:
Please read the following instructions carefully before submitting assignment:
It should be clear that your assignment will not get any credit if:

 The assignment is submitted after due date.
 The assignment is submitted via email.
 The assignment is copied from Internet or from any other student.
 The submitted assignment does not open or file is corrupt.
 It is in some format other than .cpp (Code File).

Note: All types of plagiarism are strictly prohibited.

For any query about the assignment, contact at CS304@vu.edu.pk

Case Study
With the technological innovation, the world has become a global village which enables us to contact people living far away from us. Distances have shrunk and people use many courier services on daily basis to send and receive gifts/letters/parcels. One of the popular courier services in Pakistan is XYZ which delivers your parcels nationally and internationally. Every parcel that is mailed by XYZ has some cost and weight associated with it. XYZ want to get an application which will keep records of shipment in computer.

Suppose you are working as a software developer in a software house and you got a task to develop a small application for courier company XYZ which should fulfill requirements given in problem statement.

Problem Statement:
Develop a small application in C++ that should allow the user of application to enter the receipt number, sender name, sender address, receiver name, receiver address, shipment fee and parcel weight. After getting required information, generate a shipment receipt and show as summary on screen.
To develop the application you need to create class with data member and member function as given below:

1. Class Parcel:
Attributes or Data Members:
Id:int
senderName:string
senderAddress:string
receiverName:string
receiverAddress:string
weight:int
fee:int
Methods/Operations/Getters/Setters:
Getter and setter functions of all data members
Constructor and Destructor
Hint: Put all data members in private part of class and getter/setters in public part of class. Create an object of Parcel class in main function, get all required information in local variables and save the information in data members of class with the help of setter functions. After saving all required information, retrieve the information with the help of object of Parcel class using getter functions.
Note: Assignment no.1 and 2 will be chained. So in first assignment you need to make application according to requirements given above. Solution of this assignment will be used in second assignment, so we recommend you to solve assignment yourself.
Sample Output:

BEST OF LUCK

+ How to Follow the New Added Discussions at Your Mail Address?

+ How to Join Subject Study Groups & Get Helping Material?

+ How to become Top Reputation, Angels, Intellectual, Featured Members & Moderators?

+ VU Students Reserves The Right to Delete Your Profile, If?


See Your Saved Posts Timeline

Views: 2403

.

+ http://bit.ly/vucodes (Link for Assignments, GDBs & Online Quizzes Solution)

+ http://bit.ly/papersvu (Link for Past Papers, Solved MCQs, Short Notes & More)

+ Click Here to Search (Looking For something at vustudents.ning.com?)

+ Click Here To Join (Our facebook study Group)

Attachments:

Replies to This Discussion

any discussion??

The file which is presently uploaded as solution couldnot run properly,

It is not showing shipment receipt (data entered as input)......

AOA anybody help me about assignment cs304

cs 304 ki assignment cpp main banani hy

kisi ne assignment bani hai k nahi

#include
#include
using namespace std;
class Parcel{
int ID;
string senderName;
string senderAddress;
string receiverName;
string receiverAddress;
int weight;
int fee;

public:

void setId(int);
void setsenderName(string);
void setsenderAddress(string);
void setreceiverName(string);
void setreceiverAddress(string);
void setweight(int );
void setfee(int );

int getId();
string getsenderName();
string getsenderAddress();
string getreceiverName();
string getreceiverAddress();
int getweight();
int getfee();
void display();

Parcel(){

ID=0;
senderName="";
senderAddress="";
receiverName="";
receiverAddress="";
weight=0;
fee=0;
}

Parcel(int id1,string sendername1,string senderaddress,string receivername,string receiveraddress,int weight,int fee){
ID=id1;
senderName= sendername1;
senderAddress=senderaddress;
receiverName=receivername;
receiverAddress=receiveraddress;
weight=weight;
fee=fee;

}
~Parcel(){

}

};

void Parcel::setId(int id1){
ID=id1;
}
void Parcel::setsenderName(string sendname1){
senderName=sendname1;
}
void Parcel::setsenderAddress(string senderaddress1){
senderAddress=senderaddress1;
}
void Parcel::setreceiverName(string receivername1){

receiverName=receivername1;
}
void Parcel::setreceiverAddress(string receiveraddress1){
receiverAddress=receiveraddress1;
}
void Parcel::setweight(int weight1){

weight=weight1;
}
void Parcel::setfee(int fee1){
fee=fee1;
}

int Parcel::getId(){
return ID;
}
string Parcel::getsenderName(){
return senderName;
}

string Parcel::getsenderAddress(){

return senderAddress;
}
string Parcel::getreceiverName(){
return receiverName;
}
string Parcel::getreceiverAddress(){

return receiverAddress;
}

int Parcel::getweight(){

return weight;
}
int Parcel::getfee(){

return fee;
}

void Parcel::display(){
cout"The Receipt No:"<"the="" sender="" name:"sendernameendl;="" address:"senderaddressendl;="" reciver="" name:"receivernameendl;="" address"receiveraddressendl;="" the="" weight(g):"weightendl;="" shipment="" charges:"feeendl"\n\n\n";="" }="" main(){="" cout"\t\t\t--------------------------------------------="">>>>>>>>>>>>"<"\t\t\t---------------------------------------------=""">>>>>>>>>>>>"<"enter="" receipt="" no:";="" cin=""">>A;
cout"Enter Sender Name:"; cin>>B;
cout"Enter Sender Address:"; cin>>C;
cout"Enter Reciver Name:"; cin>>D;
cout"Enter the Reciver Address:"; cin>>E;
cout"Enter the Weight (g):"; cin>>w;
cout"Enter the Shipment Charges:"; cin>>f;

Parcel Card(A,B,C,D,E,w,f);
cout"\n\n\n\n\n\n"; cout"---------------------------------------------->>""\n"; cout"\t\tShipment Receipt"<"----------------------------------------------=""">>""\n\n\n";

RSS

Latest Activity

shah G... replied to + M.Tariq Malik's discussion CS401 Assignment No 01 Fall 2019 Solution & Discussion in the group CS401 Computer Architecture and Assembly Language Programming
4 minutes ago
Profile Iconshah G... and Hiba Sani joined + M.Tariq Malik's group
4 minutes ago
yasir MSCS 2nd sem replied to + M.Tariq Malik's discussion CS301 Assignment No 01 Fall 2019 Solution & Discussion in the group CS301 Data Structures
7 minutes ago
Profile Iconyasir MSCS 2nd sem, MUHAMMAD USMAN and Muhammad Aamir joined + M.Tariq Malik's group
7 minutes ago
muddasir replied to + M.Tariq Malik's discussion MGT611 Assignment No 01 Fall 2019 Solution & Discussion Due Date: 14-11-2019 in the group MGT611 Business & Labor Law
8 minutes ago
muddasir joined + M.Tariq Malik's group
8 minutes ago
Muhammad Affan Muneer replied to + M.Tariq Malik's discussion MGT101 Assignment No 01 Fall 2019 Solution & Discussion Due Date: 13-11-2019 in the group MGT101 Financial Accounting
16 minutes ago
Profile IconMuhammad Affan Muneer and Siddiq khan kakar joined + M.Tariq Malik's group
16 minutes ago
Mumtaz Hussain liked + M.Tariq Malik's discussion CS101 Assignment No 01 Fall 2019 Solution & Discussion
21 minutes ago
+ ! ! ! ! ᎠixieᎠuຮt꧂ liked Usman Mughal's discussion Fall 2019 Assignment No. 1 English Comprehension (Eng101)
21 minutes ago
muddasir and Adil Iqbal are now friends
24 minutes ago
Mohsin pervaiz liked Usman Mughal's discussion Fall 2019 Assignment No. 1 English Comprehension (Eng101)
25 minutes ago
Profile IconNaeem jani and abdul ghafoor joined + M.Tariq Malik's group
31 minutes ago
Profile IconNabeel Ahmed, M IDREES and Abdul Ghaffar joined + M.Tariq Malik's group
49 minutes ago
BILAL Maher replied to + M.Tariq Malik's discussion CS401 Assignment No 01 Fall 2019 Solution & Discussion in the group CS401 Computer Architecture and Assembly Language Programming
1 hour ago
+¢αяєℓєѕѕ gιяℓ replied to Moji's discussion Assignment #1 Semester FALL 2019 Physics (PHY101)
1 hour ago
Asmat replied to + "J ɨ y ą ⋆'s discussion CS501 Assignment No 01 Fall 2019 Solution & Discussion Due Date: 12-11-2019 in the group CS501 Advance Computer Architecture
2 hours ago
+!!! NOOR UL JANAT !!!+ replied to Rana Ali's discussion Alfaz
2 hours ago
Rana Ali replied to Rana Ali's discussion Alfaz
3 hours ago
Rana Ali liked Rana Ali's discussion Alfaz
3 hours ago

Today Top Members 

© 2019   Created by + M.Tariq Malik.   Powered by

Promote Us  |  Report an Issue  |  Privacy Policy  |  Terms of Service