php hit counter

Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
CS201 assignment #5
VU Help • House Banner VU Help Virtual University Students - Assignments, Solved Papers, GDB & Exam Help Student Help Forum • Collaborative • Free Support
#1
Problem Statement: Multiplication of two objects of same class
• You are required to write a class. Class should have an array of 10 integers as its private data member.
Class should have
• A default constructor which will initialize all array elements with zero.
• Getter and setter functions
• An operator overloading function which will overload * operator for this class.

 You are required to create three objects of the same class.
 You must assign values to first and second objects through setter functions. You can either take input arrays from user or use hard coded values.
 Display the values of first and second object through getter functions.
 Multiply both objects and store the result of multiplication in third object.
 Multiplication means the 1st element of member array of object1 should be multiplied by 1st element of member array of object2. Similarly, 2nd element should be multiplied with 2nd and so on. In the end, display the result stored in third object.
 Your program should support the statement like a = b * c, where a, b and c are objects of the same class.

-------------------------------------------------------------------------
Sample output:
Object 1 :
1
2
3
4
5
6
7
8
9
10

Object 2 :
10
9
8
7
6
5
4
3
2
1

Multiplication of both objects :
10
18
24
28
30
30
28
24
18
10

plz give me solution.............
Reply


Messages In This Thread
CS201 assignment #5 - by usman malik - 07-11-2010, 07:16 AM
CS201 assignment #5 - by viki - 07-12-2010, 01:57 PM
CS201 assignment #5 - by usman malik - 07-13-2010, 06:29 AM
CS201 assignment #5 - by digger303 - 07-15-2010, 05:22 PM
CS201 assignment #5 - by sanam - 07-15-2010, 05:24 PM
CS201 assignment #5 - by M.Ali - 01-31-2011, 11:38 PM
CS201 assignment #5 - by Xpert - 02-01-2011, 02:35 AM
CS201 assignment #5 - by techaholic - 02-01-2011, 02:48 AM
CS201 assignment #5 - by Xpert - 02-02-2011, 01:10 AM
CS201 assignment #5 - by mohsin33 - 02-02-2011, 05:41 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Need ACC501 - Business Finance Assignment No 2 Solution. Umar Abbas 2 4,286 02-07-2014, 08:23 PM
Last Post: Umar Abbas
  sta301 assignment 4 27 jun bc110200090 6 3,622 01-26-2013, 02:05 AM
Last Post: Vuhelper
  cs506 2nd assignment millee 0 2,693 12-04-2012, 11:30 PM
Last Post: millee
  cs506 2nd Assignment Neelam Ahmad 5 3,173 12-04-2012, 11:24 PM
Last Post: Vuhelper
  CS 504 Assignment 2 need help ommmi 24 11,520 11-27-2012, 04:59 AM
Last Post: Xpert
  Urgent need Cs201 first assignmt solution r_traveler 4 2,301 11-07-2012, 01:47 AM
Last Post: Xpert
  Mcs cs402 1st assignment chahat4all 2 3,804 11-01-2012, 11:11 PM
Last Post: chahat4all
  eng201 assignment 4 due date 4/7/2012 bc110200090 6 2,647 07-03-2012, 03:51 PM
Last Post: bc110200090
  need CS304 4th assignment shazma 0 2,091 06-26-2012, 12:48 PM
Last Post: shazma
  sta301 assignment 4 solution vudecent 0 2,431 06-25-2012, 01:51 AM
Last Post: vudecent

Forum Jump:


Users browsing this thread: 1 Guest(s)
VU Help • House Banner VU Help Virtual University Students - Assignments, Solved Papers, GDB & Exam Help Student Help Forum • Collaborative • Free Support