Programming for Networking

My Coding Assignment
4 min readApr 21, 2021

This assignment assesses the basic concepts of programming; students should be able to demonstrate their achievements in the following unit learning outcomes: a. describe the fundamental principles of object-oriented programming; b. interpret a user’s needs while dealing with simple program specifications; c. design a simple class using UML notation; d. create a simple application based on UML design and the incremental development process of coding, debugging, and testing; e. apply basic control structures — sequence, repetition, and selection — to program development; f. produce simple interactive applications. Weight 25% Total Marks 50 marks Word limit Not applicable Due Date 30/05/2018 5:00PM Submission Guidelines  All work must be submitted on Moodle by the due date along with a completed Assignment Cover Page.  The assignment must be in MS Word format, 1.5 spacing, 11-pt Calibri (Body) font and 2 cm margins on all four sides of your page with appropriate section headings.  Reference sources must be cited in the text of the report, and listed appropriately at the end in a reference list using IEEE referencing style. Extension  If an extension of time to submit work is required, a Special Consideration Application must be submitted directly on AMS. You must submit this application three working days prior to the due date of the assignment. Further information is available at: http://www.mit.edu.au/about-mit/institute-publications/policies-procedures-and-guidelines/specialconsiderationdeferment Academic Misconduct  Academic Misconduct is a serious offence. Depending on the seriousness of the case, penalties can vary from a written warning or zero marks to exclusion from the course or rescinding the degree. Students should make themselves familiar with the full policy and procedure available at: http://www.mit.edu.au/about-mit/institute-publications/policies-procedures-and-guidelines/Plagiarism-Academic-Misconduct-Policy-Procedure. For further information, please refer to the Academic Integrity Section in your Unit Description. BN108D/BN108 Programming for Networking P a g e | 2 Prepared by: Umesh Poudel Moderated by: Dr Javed Ali Baloch May 2018 Assignment Description This assignment will give you practice with interactive programs, if/else statements, arrays, loops and methods. Problem Description A small car yard dealing in second hand cars needs an application to keep records of cars in stock. Details of each car shall include id (unique for each car), model, year of manufacturing, price paid for the car (i.e. purchase price) and selling price. Selling price is calculated as old price plus mark-up of 30%. For example, Ford Transit bought for $20,000 will have the selling price of 20000 * (1 + 0.3) = 26000. The car yard does not buy cars manufactured before 2009. Task Requirements Imagine you have been invited to develop a menu driven java application to manage records of cars in stock. Familiarise yourself with the problem description provided above and complete the following tasks. 1. Develop a UML class diagram based on the problem description. The name of the class must be Car a. Identify all the required attributes (includes id and selling price) for the Car class. b. Identify a constructor for the class. Attributes id and selling price are calculated fields and should not be included as constructor parameters. c. Identify all the set and get methods for each of the attributes identified in 1.a 2. Write a Java implementation of the UML diagram defined in 1. In your class, include comments describing the function of the class, the name of the programmer and the date of implementation. 3. Write a Java program (driver class) named CarYardMITnnnnn (nnnnn is your MIT ID) with a main method. Within the main method, design and implement the menu driven program functions of buying, selling, displaying and terminating the program as described below. Include comments describing the function of the program, the name of the programmer and the date of implementation. a. Declare all required variables including the list of cars (arrays/ArrayList) as static variables. b. Include static methods to implement buy, sell, and display functions BN108D/BN108 Programming for Networking P a g e | 3 Prepared by: Umesh Poudel Moderated by: Dr Javed Ali Baloch May 2018 c. Populate the list of cars (arrays) on start-up with three car objects of your choice which should be displayed when user selects option three (3) from program Menu. d. Program displays a main menu on execution and allows user to interact with the program until the user selects menu option four (4) which terminates the program. Description of Program functions Program displays a menu on execution. Four menu options are available to allow the user to buy a car, sell a car, display all cars, and exit program respectively. Program functionality and screen output for each of the menu option when selected by the user follows: View Less >>
From the above class diagram, the variables are identified as below,- The access specifies for all the variables are as public. The variables are, Id (car id) model (Model Name of the Car). Yr_manuf (Manufacturing Year of the Car) Pur_price (Purchase price of the Car) Selling_price (Selling price of the car) Constructor with parameter list identified as below,- Car(int code, String name, int year, double price) Where 4 parameters are there like id, model name, year and purchase price. Get solution

--

--

My Coding Assignment

Get Online Assignment Help From Best Assignment Help Website Instantly!!