1 answer

Given the following pseudocode: Class Coordinate Private Real _x Private Real y Public Module set_x(Real value)...

Question:

Given the following pseudocode: Class Coordinate Private Real _x Private Real y Public Module set_x(Real value) Set _X = valu
PUUTT Muule duuLUTURILE L Set x = x + c.get_x Set y = y + c.get_y() End Module End Class Module main() Declare Coordinate ci
Given the following pseudocode: Class Coordinate Private Real _x Private Real y Public Module set_x(Real value) Set _X = value End Module Public Module set_y(Real value) Set y = value End Module Public Function get_x() Return _X End Module Public Function get_y() Return y End Module Public Module add(Coordinate c) Set _X = _X + C.get_x) Set y = y + c.get_y() End Module End Class Module main() Declare Coordinate ci - New Coordinate() Declare Coordinate c2 - New Coordinate()
PUUTT Muule duuLUTURILE L Set x = x + c.get_x Set y = y + c.get_y() End Module End Class Module main() Declare Coordinate ci = New Coordinate() Declare Coordinate c2 = New Coordinate() Call c1.set_x(1.0) Call c1.set_y(2.0) Call c2.set_x(3.0) Call c2. set y(4.0) Display c1.get_x(), c1.getyo, c2.get_x(), c2.getyo Call c1.add(c2) Display ci.get_x(), 01.gety(), c2.get_x(), c2.get_yo End Module What will be the output when the main() module is called? Separate each answer with a single space.

Answers

While solving the question, i have written the whole pseudocode along the some explanation of the code in comment fashion to help you understand the program. Consider the output written in the rectangular box as on a single line separated by single space.

sel Class Coordinate Il Declaring a clan named l coordinate Private Real se ll Declaring two real number Private Real y ll va

Module main () // calling main Module Declare coordinate c1 = New coordinate I creating new reject a of the given 1 clan coor

.

Similar Solved Questions

1 answer
II: ketone III: carboxylic acid IV: 2° alcohol V: cyclic ester II: carboxylate III: aldehyde IV:...
II: ketone III: carboxylic acid IV: 2° alcohol V: cyclic ester II: carboxylate III: aldehyde IV: epoxide V: ketone II: ketone III: carboxylic acid IV: 3° alcohol V: cyclic ester II: ether III: ketone IV: 3° alcohol V. ketone II: ketone III: carboxylic acid IV: Valcohol V/ cyclic ester 2....
1 answer
A solution is made by dissolving 41.1 g urea (CH N20), a nonelectrolyte, in 275 g...
A solution is made by dissolving 41.1 g urea (CH N20), a nonelectrolyte, in 275 g water. Calculate the vapor pressure of this solution at 25°C and 45°C. 25°C 45°C vapor pressure of water 23.8 torr 71.9 torr vapor pressure at 25°C vapor pressure at 45°C -...
1 answer
Determine the future value of $28,000 under each of the following sets of assumptions (FV of...
Determine the future value of $28,000 under each of the following sets of assumptions (FV of $1, PV of $1, FVA of $1, PVA of $1, FVAD of $1 and PVAD of $1) (Use appropriate factor(s) from the tables provided. Round your final answers to nearest whole dollar amount.): Annual Rate Period I...
1 answer
A particular fruit's weights are normally distributed, with a mean of 623 grams and a standard...
A particular fruit's weights are normally distributed, with a mean of 623 grams and a standard deviation of 36 grams. The heaviest 15% of fruits weigh more than how many grams? Give your answer to the nearest gram....
1 answer
Two-point charges q1=+2.35nC and q2=−6.75nC are 0.100 mm apart. Point A is midway between them; point...
Two-point charges q1=+2.35nC and q2=−6.75nC are 0.100 mm apart. Point A is midway between them; point B is 0.080 mm from q1 and 0.060 m from q2. Take the electric potential to be zero at infinity. Find the potential at point A Find the potential at point B. Find the work done by the electric f...
1 answer
[The following information applies to the questions displayed below.] Data for Hermann Corporation are shown below....
[The following information applies to the questions displayed below.] Data for Hermann Corporation are shown below. Percent of Sales 100% Selling price Variable expenses Contribution margin Per Unit $130 78 $ 52 60 40% Fixed expenses are $86,000 per month and the company is selling 2,800 units per m...
1 answer
The wage bracket with holding table is used to: Multiple Choice Prepare the W-4 Compute social...
The wage bracket with holding table is used to: Multiple Choice Prepare the W-4 Compute social security withholding. Compute Medica re withholding. Compute unemployment taxes. Prepare the W-4 Compute social security withholding. Compute Medicare withholding. Compute unemployment taxes Compute federa...
1 answer
To maximize V(F), managers should make the CCC as (_______) as possible. The CCC represents the...
To maximize V(F), managers should make the CCC as (_______) as possible. The CCC represents the time period for (______) period...
1 answer
A 4.03-F and a 5.85-F capacitor are connected in series across a 40.0-V battery. A 6.52-F...
A 4.03-F and a 5.85-F capacitor are connected in series across a 40.0-V battery. A 6.52-F capacitor is then connected in parallel across the 4.03-F capacitor. Determine the voltage across the 6.52-F capacitor....
1 answer
Grouper Construction Company has entered into a contract beginning January 1, 2020, to build a parking...
Grouper Construction Company has entered into a contract beginning January 1, 2020, to build a parking complex. It has been estimated that the complex will cost $606,000 and will take 3 years to construct. The complex will be billed to the purchasing company at $896,000. The following data pertain t...
1 answer
For each of the following questions, provide the missing reagents (that can be purchased) and conditions or predic...
For each of the following questions, provide the missing reagents (that can be purchased) and conditions or predict the MAJOR product. Indicate stereochemistry and identify a racemic mixture if applicable. If no reaction occurs, write out "no reaction." . a. d. Ag,O/NH,OH "ОН...
1 answer
Des x Lv2] Online teaching and les onm /lim/takeAssignment/takeCovalentActivity do?locator-assignment-take&take... e desn Use the References to...
Des x Lv2] Online teaching and les onm /lim/takeAssignment/takeCovalentActivity do?locator-assignment-take&take... e desn Use the References to access important values if needed for this question. Which sample contains the greatest number of atoms. A sample of Cu that contains 2.71x1024 atoms or...
1 answer
Question 4 4 pts Tokiko is 9 months pregnant and her doctor just gave her a...
Question 4 4 pts Tokiko is 9 months pregnant and her doctor just gave her a dose of a synthetic oxytocin. Why would a doctor administer this at the end of her pregnancy? O It will help increase the lung capacity of the baby. Oxytocin will help stimulate contractions and progress labor. This will hel...
2 answers
List the three types of chemical bonds and explain the differences among them?
List the three types of chemical bonds and explain the differences among them?...