Question: C# using visual studio Create an app that includes the Auto class provided. Create a collection of type List named autos using the data provided.

C# using visual studio
Create an app that includes the Auto class provided. Create a collection of type List named autos using the data provided. Use LINQ within the app to:
List the VIN and Mak(e)/(M)odel of all autos in the autos collection in order by list price descending.
Write a query named hondas that returns the set of all Honda Civics. Show the set of hondas using the ShowAutos method provided.
Use hondas to show the number of Honda Civics and the average list price of the Honda Civics. Avoid any exception if no Honda Civics exist.
Use extension method Last() to remove the last Honda Civic from the autos collection and put it back in as the first auto. Then, show the set of hondas again.
Write a query named profits that uses hondas to return the Profit property of the Honda Civics. Display the sum of the profits, shown below as $1,848.20.
The previous sum is based on a 10% profit margin, which is the same for all vehicles. (The profit margin is the difference between Cost and List) Add to the Book class a property named Margin to represent this profit margin. Initialize Margin to 10% within the Auto class. Only allow values between 0% and 40%. Adjust the List property to use the new Margin property. Use your app to raise the margin to 15%. After raising the margin, display the new sum of the profits of the Honda Civics.
Part III
Add yourself as an employee to the first position of the collection. Use an object initializer with
name only.
Add a static property named RaisePercentage with an initial value of 10% to the Employee class.
Create a static method named IncreaseRaise that increases the raise percentage by 1%. Call the
method after displaying the employees. Then give all employees a raise and display the new
raise percentage and monthly salaries.
Employees before increasing raise from 10%
# Name Monthly Annual
Tim Brown
Tom Thompson
Georgia Kenedy
Pete Peterson
Jean Cummings
Michael Robbins
Polly Marks
Employees after increasing raise to 11%
# Name Monthly
Annual
Tim Brown
$0.00
$0.00
Tom Thompson
Georgia Kenedy
Pete Peterson
Jean Cummings
Michael Robbins
$1,343.10
$16,117.20
$1,611.72
$19,340.64
$1,450.55
$17,406.58
$2,095.24
$25,142.83
Polly Marks
$1,465.20
$17,582.40
$0.00
$0.00 Write a query named hondas that returns the set of all Honda Civics. Show the set of hondas
using the ShowAutos method provided.
Use hondas to show the number of Honda Civics and the average list price of the Honda Civics.
Avoid any exception if no Honda Civics exist.
Part 3- Number of Honda Civics in stock: 3
Average Honda Civic list price: $6,776.73 Average Honda Civic list price: $6,776.73
Use extension method Last() to remove the last Honda Civic from the autos collection and put it
back in as the first auto. Then, show the set of hondas again. Write a query named profits that uses hondas to return the Profit property of the Honda Civics.
Display the sum of the profits, shown below as $1,848.20.
Part 5- Sum of profits: $1,848.20
The previous sum is based on a 10% profit margin, which is the same for all vehicles. (The profit
margin is the difference between Cost and List) Add to the Book class a property named Margin
to represent this profit margin. Initialize Margin to 10% within the Auto class. Only allow values
between 0% and 40%. Adjust the List property to use the new Margin property. Use your app to
raise the margin to 15%. After raising the margin, display the new sum of the profits of the
Honda Civics.
Part 6- Sum of profits after margin increase to 15% : $2,772.30
C# using visual studio Create an app that

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!