Creating a package delivery system

Assignment Help Programming Languages
Reference no: EM131243654

Object Oriented Programming & Design Methodologies Assignment

For this assignment, you will be  creating a package delivery system. You need to think in terms of objects. The first object is the delivery truck that can store 50 liters of petrol. The cost per liter of petrol is 2.73$. You will be using the sample file, Drivers.txt for this assignment. Your code should however take into account that if an entry is increased or reduced (5 lines per entry) it reads all the entries in the file.

For example, if there is just one entry, it should give the following lines as output:

Elton John

34

218

9

7

Based on this entry, the driver's name is Elton John, his truck has 34 liters already, his total funds are 218$. His truck covers 9 km per liter if empty and 7 km per liter when loaded.

The trucks can carry 12 to 20 packages with random dimensions. The length, width and height of every package can range from 5 to 30 inches. This means that you will need to declare a dynamic array of boxes for each truck and every box will have a different dimension.

Calculate the total cost it will take the loaded truck to travel 60 km, drop the cargo and return empty based on the fuel consumption when the tank was full. This means that the drivers need to fill the tank first before making the journey. Based on the amount of money they have, calculate if everyone can do the journey. This means that you will need to declare a dynamic array of Trucks as well.

The sample code given is in structures, convert that to CLASSES.  Keep in mind that the attributes/variables MUST be private.

When unloading the boxes show the volume of all the boxes and then deallocate the array of boxes.

Once the trucks return, deallocate the array of all trucks after calculating the cost for the trip.

Bonus Work (If done properly, one of your previous assignments will get full marks)

The packages can only be loaded in descending order of volume, which means that the largest package will go in first. The packages can only be unloaded in ascending order of volume that is, the smallest package first. The output should be given in terms of package number, not volume. Only attempt this if you have extra time and need the bonus marks. (HINT: You need not use one array only for this). Global variables or vectors are not allowed.

Attachment:- Assignment.zip

Reference no: EM131243654

Questions Cloud

Justify your suggestion to update to star topology : 2-3 pages, APA citation, Your company is in the process of upgrading the network infrastructure, which involves moving from a 10BaseT to 100BaseT network. Currently, they use Bus topology in the network. As a member of the data network team, you a..
What might justin himself have done to enhance likelihood : What might Justin himself have done to enhance the likelihood of success in his new assignment and to help avoid derailing an otherwise highly promising career in Compcorp?
Complexity of performing operations on arrays : Discuss how the complexity of performing operations on arrays goes up when moving from one-dimensional to (square) two-dimensional arrays (linear to quadratic complexity).
What is the overall significance of the regression : Interpret the preceding regression taking into account any prior expectations that you may have about the signs of the various coefficients.
Creating a package delivery system : CS-224: Object Oriented Programming & Design Methodologies Assignment. For this assignment, you will be  creating a package delivery system. You need to think in terms of objects. The first object is the delivery truck that can store 50 liters of p..
Calculate var under the black scholes model : By equating this to the price of an ATMF straddle under the normal model with standard deviation ψ, find an equivalence between σ and ψ.
What is the income elasticity of demand for cigarettes : What is the elasticity of demand for cigarettes with respect to price? Is it statistically significant? If so, is it statistically different from one?
Next caper somewhere on pennsylvania avenue : Holy digits Batman! The Riddler is planning his next caper somewhere on Pennsylvania Avenue. In his usual sporting fashion, he has left the address in the form of a puzzle. The address on Pennsylvania is a four-digit number where:
Should the interest rate variable be retained in the model : See if the Cobb-Douglas production function fits the data given in the table and interpret the results. What general conclusion do you draw?

Reviews

Write a Review

Programming Languages Questions & Answers

  What''s the significance of the programming language

What are you going to recommend and why - again with reference to his remarks

  Write program which functions similarly to atm

Write program which functions similarly to the ATM. A user must be able to give their account number, choose whether they want to make a deposit or a withdrawal

  Draw a line joining the first two points

Write a program that allows the user to specify a triangle with three mouse presses - Draw a line joining the first two points. After the third mouse press, draw the entire triangle.

  Create a matrix the same size as omega

EENG 330: Microelectronics - Create a frequency vector called, omega which has one row and whose columns contain the elements 0.0, 0.02, 0.04, ..., 7.0 such that MATLAB does not print out the result in the command window - Create a matrix the same ..

  Write a test harness for these classes

Write an interface IClown that defines one method Honk(). Modify the TallGuyClown class to implement that interface so that calling Honk() will display a MessageBox (as above) that says "Honk my horn!". Add a property FunnyThingIHave to the interf..

  Creating table-find employee attended meeting on given date

The rows of this table record the fact that an employee from a particular project attended a meeting on the given date.

  Cloud computing significantly improve public sector it

Cloud computing can significantly improve public sector IT.A number of government agencies are adopting cloud technologies and are realizing considerable benefits. For instance, NASA Nebula,5 through a community cloud, gives researchers access to ..

  Write a code to find the mean-median and mode

Use computer program to write a code (choose any language)to find the mean, median, mode ,variance and standard deviation.

  Create program that uses array of shape

Create a program that uses an array of Shape references to objects of each concrete class in the hierarchy. The program should print a text description of the object to which each array elements

  Write a c# application that generates a 3-digit random no

Every 10th number you should display a String consisting of a any phrase of your choice concatenated with the current random number.

  Modify the inventory program by creating a subclass

Modify the Inventory Program by creating a subclass of the selected product's class that uses one additional unique feature of the product that has been selected for you. You must use the subclass name and additional unique feature

  Explain how array simplifies program development

Describe the requirement for complex data structures and how they are utilized. Describe the design and application of arrays and how array simplifies program development.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd