CIS201 Program Assignment 3

Question # 00748559 Posted By: dr.tony Updated on: 01/11/2020 04:44 AM Due on: 01/11/2020
Subject Education Topic General Education Tutorials:
Question
Dot Image

CIS201 Program Assignment 3

Description

Capital assets (cars, equipment, buildings etc.) are not expensed when you buy them but are depreciated over their estimated useful life (n). With a straight-line method of depreciation each year the capital asset depreciates (1/n)th of its cost (minus salvage value which is the value it can be sold for at the end of its useful life). Thus if an asset costs $21,000 has a salvage value of $1,000 and a useful life of 4 years its annual depreciation is figured:

($21,000 - $1,000)/4 = $5,000 a year

Its depreciation schedule would look like this (based on the asset being purchased in 2015):

 

The ending value at the end of year 4 would be the salvage value.

Write a program that:

· Include section comments (one for the program and sections of the program) and any line comments needed (for lines of code that are not obvious to another programmer)

· Start by declaring all variables needed (and any constants if applicable)

· Make sure you initialize all variables to their null value

· Have an explanatory print statement to explain to the user what the program is about and how to enter data

· You will need to prompt for input of:

· Start with a print statement explaining to the user not to leave input blank and enter numeric data where applicable

· The asset name

· Use a while loop to make sure the user enters the correct information. Remember this is a string and so the value error code will not work on this.

· The year the asset was purchased

· Use the While Value Error Loop to make sure the user enters correct data

· The cost of the asset

· Use the While Value Error Loop to make sure the user enters correct data

· The salvage value of the asset

· Use the While Value Error Loop to make sure the user enters correct data

· The useful life of the asset

· Use the While Value Error Loop to make sure the user enters correct data

· Use new line code to put spacing in for readability of prompts, have prompts free of grammar and spelling errors and if currency use the $ in the prompt

· Once the user enters the input you will need to complete:

· Calculations for straight-line depreciation

· Set up any variables for looping (this could be dependent on how you go about the loop

· Initial output (see figure below)

· Use a for loop statement to create the depreciation table (it will include columns as per the picture below)

· The for-loop will be based on the useful life of the asset

· Output:

· Will be similar to the screen below (it does not need to be exact but, should have a table format for the depreciation schedule and show the information from input used for depreciation.

· All currency will have the dollar sign, comma and taken to 2 decimal places

 

 

Please make sure you are completing your own work. There is no possible way 2 people can create the exact same program code. Remember if you share your files both the student who submitted another student’s file and the person who gave the file to that student will get a zero (0) on the assignment.

Dot Image
Tutorials for this Question
  1. Tutorial # 00747143 Posted By: dr.tony Posted on: 01/11/2020 04:45 AM
    Puchased By: 2
    Tutorial Preview
    The solution of CIS201 Program Assignment 3...
    Attachments
    CIS201_Program_Assignment_3.ZIP (18.96 KB)

Great! We have found the solution of this question!

Whatsapp Lisa