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
Arlecino [84]
3 years ago
12

Driving is expensive. Write a program with a car's miles/gallon and gas dollars/gallon (both floats) as input, and output the ga

s cost for 10 miles, 50 miles, and 400 miles.
Ex: If the input is 20.0 3.1599, the output is:

1.57995 7.89975 63.198

Needs to be in Coral language
Computers and Technology
2 answers:
Tems11 [23]3 years ago
8 0

Answer:

def driving_cost(driven_miles, miles_per_gallon, dollars_per_gallon):

  gallon_used = driven_miles / miles_per_gallon

  cost = gallon_used * dollars_per_gallon  

  return cost  

miles_per_gallon = float(input(""))

dollars_per_gallon = float(input(""))

cost1 = driving_cost(10, miles_per_gallon, dollars_per_gallon)

cost2 = driving_cost(50, miles_per_gallon, dollars_per_gallon)

cost3 = driving_cost(400, miles_per_gallon, dollars_per_gallon)

print("%.2f" % cost1)

print("%.2f" % cost2)

print("%.2f" % cost3)

Explanation:

Ierofanga [76]3 years ago
6 0

Answer:

x^{2} \left[\begin{array}{ccc}1&2&3\\4&5&6\\7&8&9\end{array}\right] \int\limits^a_b {x} \, dx  \lim_{n \to \infty} a_n \sqrt{x} \sqrt[n]{x} \pi \alpha \frac{x}{y} x_{123} \beta

Explanation:

You might be interested in
As in algebra, you can use brackets to override the order of operations Excel follows to perform formula calculations. True or f
sertanlavr [38]

Answer:

false

Explanation:

parasynthesis is used to change the order of priority.

6 0
4 years ago
Jane, an employee in the human resources department, has created several important PDF documents on her computer that all office
Colt1911 [192]

Answer:

Share documents and set specific permissions.

Explanation:

For a computer network with Windows OS Jane and the technician can create a Shared Folder by right-clicking on it and selecting properties.

Then on the Share and Security tabs of the properties, they can set which specific users and/or roles will have access to the shared folder. They will also have to set what permission level will be granted, such as <em>full access, read only, etc.</em>

The managers can access the shared files using <em>Windows explorer</em> either by searching shared folders in their Network, or by typing the shared folder address usually something like \\JANE_PC/SharedFolder.

6 0
3 years ago
Read 2 more answers
It is very easy to change data into charts<br> what is a Microsoft Excel Microsoft Outlook or both​
Vadim26 [7]
It’s microsoft Excel
8 0
3 years ago
Write an application that solicits and inputs three integers from the user and then displays the sum, average, product, smallest
Oksana_A [137]

Answer:

Please find below program

Explanation:

import java.util.Scanner;

public class Tester {

public static void main(String[] args) {

 

 // create an object of scanner class

 Scanner scanner  = new Scanner(System.in);

 

 //prompt user to enter first number

 System.out.println("Enter first integer: ");

 

 // read value from entered by user and keep it in num1

 int num1 = scanner.nextInt();

 

 //prompt user to enter second number

 System.out.println("Enter second integer: ");

 

 // read value from entered by user and keep it in num2

 int num2 = scanner.nextInt();

 

 //prompt user to enter third number

 System.out.println("Enter third integer: ");

 

 // read value from entered by user and keep it in num3

 int num3 = scanner.nextInt();

 //close scanner as we have done with user input

 scanner.close();

 

 //calculate sum

 int sum = num1+num2+num3;

 

 //calculate average

 int average = sum/3;

 

 //calculate product

 int product = num1*num2*num3;

 

 //find out largest number

 int largest = 0;

 if (num1>=num2){

  if(num1>=num3)

   largest = num1;

  else

   largest = num3;

 }else {

  if(num2>=num3)

   largest = num2;

  else

   largest = num3;

 }

 

 // find out smallest number

 int smallest = 0;

 if (num1<=num2){

  if(num1<=num3)

   smallest = num1;

  else

   smallest = num3;

 }else {

  if(num2<=num3)

   smallest = num2;

  else

   smallest = num3;

 }

 

 // print all the information

 System.out.println("Sum of three numbers : "+sum);

 System.out.println("Product of three numbers : "+product);

 System.out.println("Average of three numbers : "+average);

 System.out.println("Smallest number : "+smallest);

 System.out.println("Largest number : "+largest);

}

}

3 0
4 years ago
Frank listed the steps for attaching a file to an e-mail. Step 1: Create the message. Step 2: Click Attach File in the Include g
Leya [2.2K]
Step 1: Create the message was frank's error in sending a file to an e-mail. This is because, when sending a copy of an e-mail the sender must make sure to input the e-mail address of the receiver on the top of the message box. This way the sender will be sure to submit his attachment to the receiver properly.
5 0
4 years ago
Read 2 more answers
Other questions:
  • Your friends’ preschool-age daughter Madison has recently learned to spell some simple words. To help encourage this, her parent
    8·1 answer
  • Kaira's company recently switched to a new calendaring system provided by a vendor. Kaira and other users connect to the system,
    11·1 answer
  • (6 pts) Write a bash shell script called 08-numMajors that will do the following: i. Read data from a class enrollment file that
    10·1 answer
  • How will you ensure that all of the network's applications and tcp/ip services also support ipv6?
    10·1 answer
  • A company has a five-member team in charge of development and maintenance of its information systems. An information system is i
    14·1 answer
  • _____ parser is an LL parser that is implemented by writing code directly from the grammar of the source language. EBNF is ideal
    7·1 answer
  • Which statement best describes desktop publishing?
    10·1 answer
  • El planeamiento estratégico de una empresa es​
    9·1 answer
  • Project light with a system of lenses used for projecting slides or film into a screen.
    5·1 answer
  • A co-worker is called away for a short errand and leave the clinical PC logged onto the Confidential Information System. You nee
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!