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
ser-zykov [4K]
3 years ago
6

A cookie recipe calls for the following ingredients: • 1.5 cups of sugar • 1 cup of butter • 2.75 cups of flour The recipe produ

ces 48 cookies with this amount of ingredients. Write a program that asks the user how many cookies they want to make and then displays the number of cups of each ingredient needed for the specified number of cookies in the following format: You need 5 cups of sugar, 3 cups of butter, and 7 cups of flour. Note: Don’t worry about formatting the numbers in the output.
Computers and Technology
1 answer:
erastovalidia [21]3 years ago
6 0

Answer:

<em>This program is written using c++ programming language</em>

<em>Comments are used to explain difficult lines</em>

<em>See attachment for .cpp source files</em>

<em>Program starts here</em>

#include<iostream>

using namespace std;

int main()

{

// Calculate number of ingredient that makes up 48 cookies

float num_sugar = 1.5/48;

float num_butter =1.0/48;

float num_flour = 2.75/48;

//Declare integer variable to get number of cookies from user

int n;

// Prompt user for number of cookies needed

cout<<"Enter number of cookies: ";

cin>>n;

// Calculate equivalent amount of ingredient

num_sugar *= n;

num_butter *= n;

num_flour *= n;

// Display Result

cout<<"You need "<<num_sugar<<" cups of sugar, "<<num_butter<<" cups of butter, and "<<num_flour<<" cups of flour.";

return 0;

}

//End of Program

Download cpp
You might be interested in
Review the portion of the application above. Record any changes or corrections that need to be made and why.
crimeas [40]

Answer:

Necessary Corrections: First Name and Last Name are recorded in incorrect boxes. Scribbles on errors instead of making corrections Does not include information in the SSN or Desired Salary blank Does not list which position she is applying for Has box checked that she has worked for the company, but does not say when For education just wrote “Yes” instead of listing the high school and address Justification: All of this make the applicant appear less professional and hurt her chances of getting hired. She is not following the directions properly, and she is not asking questions so that she can accurately fill out the application.

(I got a 100% so I know its correct)

4 0
2 years ago
How does classless inter-domain routing (cidr) help reduce waste of ip addresses?
Scorpion4ik [409]
It allows for more accurate sizing of networks.
4 0
3 years ago
Allie is working on the development of a web browser and wants to make sure that the browser correctly implements the Hypertext
creativ13 [48]

Answer:

The answer is "Option c"

Explanation:

The W3C is the framework for the creation of software and the online standards through which sites and webpages work, and to turn into an authoritative source of information, she will work towards getting a reliable and credible source of knowledge from the "World Wide Web Consortium", and the wrong option can be described as follows:

  • In option a, It is wrong because this organization prepares and publishes all the electronic technologies.
  • In option b, It is wrong because it is the laboratory of physics, which is not useful in web development.
  • In option d, This technology is used in TCP/IP protocol, that's why it is incorrect.
3 0
3 years ago
if someone has become very attached to their mobile device and feels anxious if the cannot connect to the internet, what are the
svp [43]

Answer:

Anxiety

Explanation:

trust I have it

4 0
3 years ago
6. Which of the following is malware? (1 point)
lubasha [3.4K]
Software to damage computers
5 0
3 years ago
Read 2 more answers
Other questions:
  • What is html?
    9·2 answers
  • How does an employer judge a candidate?<br> The employer judge's the candidate's ? for a job.
    12·1 answer
  • The approved systems design document is used by programmers, the personnel department, and information systems personnel.
    8·1 answer
  • Which protocol do many browsers assume when you enter a URL in the address field?
    9·1 answer
  • Create a class named Circle with fields named radius, diameter, and area. Include a constructor that sets the radius to 1 and ca
    7·1 answer
  • Which of the following is an example of hypertext pattern reading?
    13·1 answer
  • Which line of code will find the first occurrence of a three in an array?
    5·2 answers
  • Write a program to simulate a Fruit Machine that displays three symbols at random from Cherry, Bell, Lemon, Orange, Star, Skull.
    11·1 answer
  • 30 Points!!
    13·2 answers
  • The arrangement of keys on a keyboard, QWERTY reflects the keyboard layout by ________. Group of answer choices using the letter
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!