Latest Activity In Study Groups

Join Your Study Groups

VU Past Papers, MCQs and More

We non-commercial site working hard since 2009 to facilitate learning Read More. We can't keep up without your support. Donate.

Dear Students,

The solutions of assignment # 5 that are posted here till now are not correct, The perfect solution consist of less then 100 lines of code, there are many wrong solutions of more then 300 lines of code, be careful, think before submit, as previous i must post perfect solution before grace day, wait for perfection,

keep smiling

Best of Luck 

Views: 2039

Replies to This Discussion

Dear Students,

The solutions of assignment # 5 that are posted here till now are not correct, The perfect solution consist of less then 100 lines of code, there are many wrong solutions of more then 300 lines of code, be careful, think before submit, as previous i must post perfect solution before grace day, wait for perfection,

keep smiling

Best of Luck 

 

Tahir bhai y r u delaying it on grace day???? light ki kitni prob hai & kbhi lms mein prob ajati hai..plz it could b risky..ap ne sol dena hi hai to plz aj last date hai aj de dein..it will b very kind of u...

Thank you..!!

plz correct solution aj hi upload kry.....

Tahir mere bhia,, k do jani aj he,,,, q wait krwa rahy ho hum ghribo ko

inta wait kon karta hi light chali jaye gey

#include<iostream.h>
#include<conio.h>

using namespace std;

// ************************ Customer Class **************************

class Customer
{
private:      // ************* Private Data Members
        char Name[100];
        int CustomerID, Spending ;
public:      
       Customer();              // Simple Constructor
       friend ostream &operator ( ostream & , Customer & ) ; // Overloaded operator
       friend istream &operator >> (istream & , Customer & ) ; // Overloaded >> operator
};


int main()
{
         cout "\n" ;
         Customer obj ;     
         cin >> obj ;      
         cout obj ;      
 
    system ("PAUSE") ;
    return 0;
}

/* ************************ Constructor Definition */
Customer::Customer()
{
                    strcpy ( Name , "No Name" ) ;
                    CustomerID = Spending = 0 ;
}

/* ************************ operator   Definition */
ostream &operator ( ostream &out , Customer &obj )
{
        out "\n\n**************************Customer Billing Information*************************\n\n";
        out "  Name     *************** " obj.Name "\n";
        out "  ID       *************** " obj.CustomerID "\n";
        out "  Spending *************** " obj.Spending "\n";
        
        float Tax, Discount;
        
        if(obj.Spending<5000)
        {
                             Tax = obj.Spending*.05 ;
                             Discount = obj.Spending*.01 ;
        }
        
        else if(obj.Spending<10000)
        {
                             Tax = obj.Spending*.1 ;
                             Discount = obj.Spending*.02 ;
        }
        
        else 
        {
                             Tax = obj.Spending*.15 ;
                             Discount = obj.Spending*.03 ;
        }

        out "  Tax      *************** " Tax "\n" ;
        out "  Discount *************** " Discount "\n" ;
        out "  Total    *************** " obj.Spending+Tax-Discount "\n" ;
        return out;
}

/* ************************ operator >>  Definition */
istream &operator >> (istream &in, Customer &obj)
{
        cout " Enter name of the customer : " ;
        in.getline( obj.Name , 100 , '\n' ) ;        
        cout " Enter ID of the customer : " ;
        return in;
}

check this

this is not the required solution

17 errors hain..........

TAHIR PLZ AP SOL JALDI UPLOAD KR DAIN NA ..... YAHN TO CAMPUS MAI B LITE NAI HOTI ....!

hmmm

Tahir Ramzan

good keep it up

i hope tahir  u must upload the solution today...............

intahi beycar site hi

useless website

RSS

Looking For Something? Search Below

Latest Activity

+ ! zεε liked иαвєєℓ αнмє∂'s discussion CS619 Project Students
4 hours ago
Hamid left a comment for jiya ali
5 hours ago
Hamid and jiya ali are now friends
5 hours ago
Usama shahid joined + M.Tariq Malik's group
12 hours ago
Yasir Hassan liked + ♥ Haniya Khan's photo
13 hours ago
Profile Iconsria aslam, Khawir Abbas and Sana Shafaq joined Virtual University of Pakistan
16 hours ago
+ ♥ Haniya Khan posted a photo
yesterday
Abdul Rehman updated their profile
Saturday

VIP Member Badge & Others

How to Get This Badge at Your Profile DP

------------------------------------

Management: Admins ::: Moderators

Other Awards Badges List Moderators Group

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

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