Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Objectives Practice and test your understanding of the following imperative programming concepts using C as programming language: Control statements Loops Local Variables Header and Source
Objectives
Practice and test your understanding of the following imperative programming concepts using C as
programming language:
Control statements
Loops
Local Variables
Header and Source Files
Good Coding Practices
User Input
Functions
Structures
Arrays
Pointers
Calculate Projects Performance
Proper planning is crucial for project success and makes project implementation go smoother. You might
have heard this saying before: If you fail to plan, you plan to fail A projects life cycle can be divided
into multiple stages: Planning, Implementation and Closing.
At the planning stage, any project is usually divided into several milestones. During the project planning
stage, each milestone will be assigned a timeline number of hours needed number of employees, and a
budget. During the implementation stage, the actual values will be recorded to be used during the closing
stage to evaluate the projects performance in regard to time and cost.
Recording these values is important for planning future projects, as you can learn from your mistakes,
successes, and previous experiences.
The Problem
ABC Company hired you to write a software to help them managing their projects.
They want to keep track of the planned values and the actual values which at the end of the project will be
the final values
Their projects usually have up to five main milestones. For each milestone, they need to store:
Id must be unique
Name
Planned cost $
Actual cost $
Planned duration days
Actual duration days
Number of employees assigned to the milestone. Note that this value will not change throughout
the project execution
If the milestone is already completed or not
For the project, you need to store:
Name
Planned cost $
Actual cost $
Planned duration days
Actual duration days
If the project is already completed or not
Detailed explanation of the flow chart
Welcome message.
o There should be a welcome message when you start the application.
Enter the projects name and number of milestones.
o Prompt the user to enter the two values mentioned above.
o You can assume that the project name contains no spaces.
o Note: The number of milestones must be a positive value between one and five. If the user enters
an invalid value, ask them to enter another value.
Initialize all milestones.
o Id: Prompt the user to enter the value. You can assume that the user will enter unique values.
The id must be positive.
o Name: Prompt the user to enter the value.
o Planned cost $: Calculated as follows:
Planned Cost Planned Durationdays x Numberemployees x salaryday
In the company, each employee works hoursday and their salary is $hour
o Actual cost $: Initialized to zero.
o Planned duration days: Prompt the user to enter the value. If the user enters an invalid value,
inform the user and ask for a new value.
o Actual duration days: Initialized to zero.
o Number of employees assigned to the milestone: Prompt the user to enter the value. If the
user enters an invalid value, inform the user and ask for a new value.
o If the milestone is already completed or not: Initialized as not completed.
Initialize the project.
o Name: Use the value entered by the user in point
o Planned cost $: Sum of the planned cost from all milestones.
o Actual cost $: Initialized to zero.
o Planned duration days: Sum of the planned duration from all milestones.
o Actual duration days: Initialized to zero.
o If the project is already completed or not: Initialized as not completed.
Print the main menu.
Please select one of the following options:
Update milestone
Print stats
Exit
Get user choice.
Ask the user for a choice and check if the user input is between and
o If not between and output an error message and ask the user to enter a new choice.
o If the input is end the program.
o If the input is print the project stats and return to the main menu.
You should display:
Project name
If the project is completed or not
If the project is completed:
How much the project was over budget or underbudget.
How early or delayed the project was.
If the project is not completed:
For the milestones that have been completed:
o The name of the milestone
o How much the milestone was over budget or underbudget.
o How early or delayed the milestone was.
For the milestones that have not been completed:
o The name of the milestone.
o Planned duration.
o Planned cost.
o If the input is print the submenu.
The submenu will list the IDs and names of the milestones and whether they are completed or
not.
Get user choice.
If the use choice is not one of the IDs of the milestones listed as not completed, output
an error message and ask the user to enter a new choice.
If the use choice is one of the IDs of the milestones listed as not completed:
o Update the milestone details as follows:
Prompt the user to update the actual duration.Designed Solutio
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started