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
Xelga [282]
2 years ago
6

When you are making multiples of a brownie recipe, you cannot - without great difficulty - use a fraction of an egg. The calcula

te_eggs function uses the ceil function in the math module to always round up and provide the total number of eggs you need on hand to make your recipe.
1. On Line 2, import just the ceil function from the math module
2. On Line 6, call the ceil function to calculate 0.6*servings
When you run the code, it should match the output under Desired Output
# Import ceil function only from the math module
import math.ceil
# Define Function
def calculate_eggs(servings):
total_eggs = (0.6*servings)
return total_eggs
# Call Function
print(calculate_eggs(14))
Desired Output = You need 9 eggs
Computers and Technology
1 answer:
Lera25 [3.4K]2 years ago
5 0
The answer is one ☝️ question for the poll of a vote
You might be interested in
Here's something random idc
melisa1 [442]

Answer:

ey ey

Explanation:

3 0
3 years ago
Read 2 more answers
Fiona is creating a presentation with PowerPoint Online about how pencils are made. She would like to type an explanation about
777dan777 [17]

Answer:THE ANSWER IS A.

Explanation:I DID IT AND I GOT 100

6 0
2 years ago
PLEASE HELP ILL GIVE POINTD AND BRAINLIEST
Nastasia [14]

Answer:

I would have to say C.

Explanation:

Feel free to correct me if i'm wrong :)

Hope this helps

4 0
3 years ago
A Function checkMe takes three parameters, a character and two integers. If the sum of the two integers is negative, and the cha
Paul [167]

Answer:

Check the explanation

Explanation:

Here is the program with function definition and two sample calls.

Code:

#include <iostream>

using namespace std;

//checkMe FUNCTION which takes values a, b and c

void checkMe(char &a, int &b, int &c)

{

//if sum of b and c is negative and a is 'n', b and c are set to 0, otherwise a is set to 'p'

if((b+c)<0 && a=='n')

{

b = 0;

c = 0;

}

else

{

a = 'p';

}

}

int main()

{

//first test case when else part is executed

char a = 'n';

int b = 5;

int c = 6;

 

checkMe(a, b, c);

 

cout<<a<<" "<<b<<" "<<c<<endl;

 

//second test case when if part is executed

a = 'n';

b = -4;

c = -5;

 

checkMe(a, b, c);

 

cout<<a<<" "<<b<<" "<<c<<endl;

return 0;

}

Kindly check the Output below:

7 0
3 years ago
In the following code segment, assume that the ArrayList numList has been properly declared and initialized to contain the Integ
KATRIN_1 [288]

Answer:

e. 4

Explanation:

The code segment will not work as intended if the value of the variable val is 4. This is because the while loop is comparing the value of the variable val to the value of each element within the numList. Since there is no element that is bigger than or equal to the number 4, this means that if the variable val is given the value of 4 it will become an infinite loop. This would cause the program to crash and not work as intended.

8 0
3 years ago
Other questions:
  • When you tell an acquaintance your telephone number, you do not recite the digits one by one at a constant rate, as in "3, 3, 7,
    11·1 answer
  • If one breakfast meal of banana lacatan, scrambled egg, plain rice, and hot milk contains 58 grams carbohydrate, 12 grams protei
    11·1 answer
  • List the seven basic internal components found in a computer tower
    12·2 answers
  • Write a function called show_info that takes a name, a home city, and a home state (a total of 3 arguments) and returns a full s
    12·1 answer
  • The Fibonacci sequence begins with 0 and then 1 follows. All subsequent values are the sumof the previous two, for example: 0, 1
    11·1 answer
  • The program DebugTwo2.cs has syntax and/or logical errors. Determine the problem(s) and fix the program.// This program greets t
    5·1 answer
  • Give several reasons why Python is such a great programming language. Explain how Python is related to flowcharts.
    9·1 answer
  • // This class calculates a waitperson's tip as 15% of the bill public class DebugThree1 { public static void main(String args[])
    10·1 answer
  • Write a program to Test if mold is stored in the variable word.
    5·1 answer
  • In order for a sort to work, which of the following is required?
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!