1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
vovikov84 [41]
3 years ago
8

Create an application that determines the final cost of food items and non-food items, assuming only non-food items are taxed. T

he interface should prompt the user for the total cost of food items and the total cost of non-food items. Display the final cost when an Answer button is clicked. Use a constant for the tax with value of 7%.
Computers and Technology
1 answer:
Maslowich3 years ago
8 0

Answer:

Write the following in the button click event:

<em>    double total = Convert.ToDouble(txtNonFood.Text) + Convert.ToDouble(txtFood.Text) * (1 + 0.07); </em>

<em>            MessageBox.Show("Total: " + total);</em>

Explanation:

The app is created using Winforms C#.

First, is to design the form using 2 labels, 2 textboxes and 1 button.

<em>The text of the labels are set to "Food Items" and "Non Food Items", respectively.</em>

<em>The name of the textboxes are set to txtFood and txtNonFood respectively.</em>

Next, is to ensure that the textboxes accept only numbers and 1 decimal point.

So, we need to create a keypress event:

<em>private void txtNonFood_KeyPress(object sender, KeyPressEventArgs e){</em>

<em />

And then, write the click event to display the total amount of items (as written in the answer section):

This calculates the total amount

<em>    double total = Convert.ToDouble(txtNonFood.Text) + Convert.ToDouble(txtFood.Text) * (1 + 0.07); </em>

<em>This prints the total amount</em>

<em>            MessageBox.Show("Total: " + total);</em>

<em>See attachment 1 for app interface & attachments 2 and 3 for complete program code</em>

You might be interested in
1.What is a project methodology?
blagie [28]

Explanation:

1. Let’s suppose that we want to test a scientific hypothesis. What we need to do first is to come up with steps and techniques for testing this hypothesis. This, in a similar way explains what project methodologies are. A project methodology gives us a properly organized way of planning and executing a substantial amount of work that needs to be completed in a given amount of time. Think of it as a game plan that you need to up with to develop a product or an IS.

2. Following a particular methodology comes with its own advantages.

  1. 1. It gets you focused on the product you are trying to come up with.
  2. 2. So many lessons will be learnt and will be documented as experiences and will be integrated as best practice. In the event that the project is a success, the same methodology can be used once again in the future.
  3. 3. Saves time since the same prescription of tools, phases, and techniques used for a particular project can be reused once more to come up with another project.

3. It maps out the existence of a project from start to finish. It is defined within a given methodology. Projects, like humans, have defined life-cycles. The same way we come out of wombs, grow, mature, decline, and then die is the same way a project has a beginning, mid, and end.

4. It does not matter whether a project one is working on is huge or not, they have to be organized into a sequence of phases for manageability. These phases include phase exits, stage gates, and kill points. Having these phases aligned together will give an organization a clear indication of how to evaluate the project’s performance and be able to mitigate problems that arise.

5. Starting the next phase just before the current one ends can sometimes be a good thing since it can reduce the schedule of the project. This is what is known as fast tracking. It is a good idea but introducing one phase before another one ends can cause an overlap and as a result can pose as a risk. Do it if the risks are within scope and can be accepted.

6. An idea that someone comes up with to build a new information system or product can be counted as one of the initiation processes of a PLC.  However, the first process is to define the goal of the project. Organizations have put amounts of time and investments into coming up with a project. Therefore, every little aspect of the project should be properly envisioned to meet the business's value. This is phase where we should ask ourselves questions like whether the project is going to be successful and how we will identify its success in correlation to the investments raised by the stakeholders. It is the phase upon which every detail is looked into carefully and goals defined before the project is flagged off.  

7. This phase provides the direction and planning for the project. Once the project has been flagged off and is ready to move forward, the team needs to define what the objectives will be, when and what time the project will be completed, and the amount of money that will be required to finish. In addition, things like how many people are we looking at to complete the project and the technology that will be used to build the project are highly considered and looked into in this phase.

8. At this point, the project must be approved first before moving on to this phase. The teams put all efforts of design, development, and delivery of the final product. Whoever has invested on the product will now start to have a clear picture of everything that is going on from the first phase of planning to the actual implementation based on time it has taken to the budget that has been so far.

9. Every beginning must always have an end and this is the phase that ensures a well-defined end. It ensures that the amount of effort and work that the teams have put in developing and implementing the product is complete. This phase also sees the team and stakeholders have meetings to try and consolidate and come into terms of whether or not the goals of the planning phase have been achieved.

10. Because every single project has its own goals and achievements that it wants to meet. Every product is unique in terms of what it wants to achieve and the principles and practices might not work for every project. It is the processes used to come up with the particular project that will play an integral part in the life cycle

Learn more about project methodologies by clicking on the link below

brainly.com/question/13821095

brainly.com/question/988326

#LearnWithBrainly

4 0
3 years ago
1.1. (30 points) Write a program to calculate the average number of cars sold by a car agency over a period of years for the fir
mario62 [17]

Answer:

count = 0

months = 0

years = int(input("Enter the number of years: "))

for year in range(1, years+1):

   cars_sold = int(input("Enter the number of cars sold in first six months: "))

   count += cars_sold

   months += 6

print("Number of months: " + str(months))

print("Number of cars sold in total: " + str(count))

print("Average number of cars sold per month: " + str(count / months))

Explanation:

Initialize the variables

Ask the user for the number of years

Create a for loop that iterates depending on the given number of years

Ask the user for the number of cars sold in the first six months of the year

Increment the count by given number and increment the months by 6 after each iteration

Print the months, count and, average

8 0
3 years ago
list the six enternal parts or peripherals of a computer system and identify which are output and which are input devices?
inn [45]
There are many peripheral devices but heres 4 external output ones: monitor, speakers, plotter, and printer. Here are also 4 peripheral input devices: mouse, keyboard, mousepad, and joystick.
3 0
4 years ago
Read 2 more answers
What do you think will happen if you use a different file format for a certain document type?
sweet-ann [11.9K]

Answer:

It will either convert the file automatically into the program so you can edit it on the different platform or it will not be able to open the document at all.

Explanation:

I have personally done this before. Usually I use Word documents, which are .doc and .docx files.

I also run a Linux based OS sometimes (dual boot) and I don't have Microsoft Office products on it. However, Linux does have their own set of products that are similar to it.

I opened a .docx file on the Linux version of Word and it did convert the file into a separate one and I was able to edit it.

However, when I then tried opening the new Linux file type on Word, it was not able to open the document at all.

Therefore, it really depends on what programs have what capabilities. Word can open .doc and .docx. Linux could open their own types as well as .doc and .docx by conversion.

A rule of thumb is just not to change the file format at all. Just stick with the original so you don't lose your file. If you cannot do so, then use a online file converter to change the file type.

3 0
3 years ago
Among all the scientists of the 1930s, ________ was sosuited to carry out the Manhattan project as J.RobertOppenheimer.
Naily [24]

Answer:

none

Explanation:

Great question, it is always good to ask away and get rid of any doubts that you may be having.

The above phrase does not have any correct entry. The correct way of stating the sentence would be the following.

"Among all the scientists of the 1930's, <u>none were as</u> suited to carry out the Manhattan Project as J. Robert Oppenheimer."

<u></u>

<u>none</u> is an available answer but since the next part of the sentence says <em><u>was so</u></em> it would not make sense or be grammatically correct. Therefore you can either change the available answers or change the next two words in order for the sentence to make sense as well as be grammatically correct.

I hope this answered your question. If you have any more questions feel free to ask away at Brainly.

4 0
3 years ago
Other questions:
  • A new company is upgrading a media workstation. The computer will be predominantly used for graphic intensive presentations, sli
    13·1 answer
  • . Dеclarе a onе-dimеnsional array of 30 doublеs (on thе stack) namеd rainfall
    11·1 answer
  • Why is ice even more dangerous than snow
    9·2 answers
  • Speculate on how students 25 years from now will answer, "What computing innovation has had a significant impact on your life?"
    11·1 answer
  • 20
    6·1 answer
  • (in order of a-z)
    12·1 answer
  • What command can you use if you accidentally delete a sentence in your document?
    13·2 answers
  • Need help with this one​
    5·1 answer
  • The function retrieveAt of the class arrayListType is written as a void function. Rewrite this function so that it is written as
    10·1 answer
  • 8. SQL, Oracle Report, and Visual Basic are all examples under the
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!