Create a class called Drive. It should have instance fields miles and gas which are both integers. Another instance field, carType, is a String. The constructor should receive a String which initializes carType. The other two instance fields are both automatically initialized to 1 in the constructor. Create a method called getGas that returns an integer that is the gas data member. The getGas method has no parameters. Write in java. First correct answer will be marked brainliest, i need answer very soon

Answers

Answer 1

public class JavaApplication87 {

   

   public static void main(String[] args) {

       Drive dr = new Drive("Insert type of car");

       System.out.println(dr.carType);

   }

   

}

class Drive{

   int miles;

   int gas;

   String carType;

   public Drive(String ct){

       carType = ct;

       miles = 1;

       gas = 1;

       

   }

   int getGas(){

       return gas;

   }

   

}

I'm pretty sure this is what you're looking for. Best of luck.


Related Questions

what is the importance of planning before you start your vegetable farm business?

Answers

Answer with Explanation:

"Planning" plays a crucial role before starting any business. If you've decided to start a vegetable farm business, then you better plan ahead.

Vegetables are "perishable," which means it is easy for them to get spoiled. Thus, you have to consider many things such as: what kind of crops to sell, where to sell them, what season you're going to sell them and how much you are going to sell them.

Choosing the kind of crop depends on whether you'll be requiring intensive labor or not. Although the former means more profit, it will require more capital. Knowing your target market is essential. For example, if your target are health-conscious people, then you have to go for organic vegetables. Determining the season to sell the vegetables will allow you to price them accordingly. Lastly, you have to know how much you're going to sell your vegetables in order for you to have an idea of the profit you're going to make. This will also allow you to budget your money.

I need help pleaseeeee!!!

Answers

Answer:

True

Explanation:

Integrated Services Digital Network (ISDN) is a set of communication standards for simultaneous digital transmission of voice, video, data, and other network services over the traditional circuits of the public switched telephone network.

Pleaseee mark me as brainliest

Hope this help <3

Joann wants to save the building block she created for the title of her company.

In which file does she save this building block?

Answers

Answer:

Building Blocks.dotx

Explanation:

Just did it on Edge2020

CORRECT ANSWER GETS BRAINLIEST!!!
Which area of engineering focuses on the study of materials, products, and structures that may cause injury or damage?
forensic engineering
mechanical engineering
biomedical engineering
materials engineering

Answers

Answer:

Forensic engineering

Explanation:

Forensic engineering matches the definition of "a area of engineering that focuses on the study of materials, products, and structures that may cause injury or damage"

Which careers require completion of secondary education, but little to no postsecondary education? Mathematical Technicians and Mechanical Engineers Sociologists and Electronics Engineering Technicians Food Science Technicians and Zoologists Nondestructive Testing Specialists and Surveying Technicians

Answers

Answer:

Nondestructive Testing Specialists and Surveying Technicians

Explanation:

A nondestructive testing specialist and surveying technician refers to an individual who is saddled with the responsibility of providing services such as the inspection of structures (aeroplane, dam, trains, reactors, bridges), machines or equipments, and raw materials in order to check for problems or any defective part.

Hence, Nondestructive Testing Specialists and Surveying Technicians is a career that requires the completion of secondary education, but little to no postsecondary education because they use equipments mainly to find detects and gather details about any problem.

Answer:

D is correct on test review

SOMEONE PLEASE HELP ME WITH THIS !!!!

Answers

I feel it is C, but I am not sure if it is correct, I can only apologize if it is wrong.

Which view would you need to use to make changes to the design theme for the entire presentation?

Answers

Apply a theme to your presentation

Open your presentation.

On the Design tab, you'll find design themes in the Themes group.

To preview how the current slide would look with a particular theme applied, rest your pointer over the thumbnail image of that theme.

To view more themes, on the Design tab, in the Themes group, click More More button at the right end of the gallery.

To select and apply a theme, click the thumbnail image of that theme.

Unless you specify otherwise, PowerPoint applies the theme you select to the entire presentation.

To apply a theme to only one or a few slides, select the slide or slides, right-click the theme you want, and select Apply to Selected Slides.

Answer:

slide master

Explanation:

the answer on edge2020

Arrange the numbers 4, 8, 2, 6, 3, 5, 0, 1 into ascending order using the Merge sort algorithm

Answers

Answer:

1 2 3 4 5 6 you are missing seven the 8

Explanation:

A group of friends go on a holiday to the mountains. On the trip, they take a lot of pictures. One of the friends uploads the pictures on his blog. Which image format is best for uploading photos? The image format is best for uploading photos.

Answers

Answer: PNG

Explanation:

PNG stands for Portable Network Graphics, with so-called “lossless” compression.

A group of friends goes on a holiday to the mountains. The image form that is best for uploading photos is PNG. The correct option is B.

What is the PNG format of the image?

To display high-quality digital images, websites frequently use the PNG file format. PNGs, which were developed to outperform GIF files, provide not just lossless compression but also a significantly wider and brighter color spectrum.

Raster image files come in both JPEG and PNG varieties. This indicates that they are composed of a set number of color pixels.

To display high-quality digital images, websites frequently use the PNG file format. PNGs, which were developed to outperform GIF files, provide not just lossless compression but also a significantly wider and brighter color spectrum.

Therefore, the correct option is B. PNG.

To learn more about the PNG format, refer to the link:

https://brainly.com/question/20293277

#SPJ2

The question is incomplete. Your most probably complete question is given below:

PNG

JPG
JPEG

GIF

Guys im getting the ps5 tomorrow :)​

Answers

Answer:

Congrats.

Probably will be better than the Xbox minifridge

Ryo currently earns a monthly salary of $2200. She has been offered a raise of $250 per month. How much more will she earn per year at her new salary?

Answers

Answer:

$3,000 more per year

Explanation:

Since the difference between her old salary and her new salary is $250 per month, then we can simply multiply this amount by the 12 months in a year in order to calculate how much more she will be earning per year on her new salary...

$250 * 12 = $3,000

Therefore, we can see that Ryo will be earning an extra $3,000 more per year with her new raise when compared to her old salary.

The shooting(blank) should describe a daily plan of the shoot and should include everything from the crew to wrap-up.

Answers

Answer:

schedule

Explanation:

Indeed, in almost every video production a shooting schedule is used to describe the daily plan of the shoot; such as what scenes to shoot first, and next.

It also gives details about the crew, as well as the timeline for the entire film production, and so on.

Question # 4
Multiple Choice
How do you stop a program that is stuck in an infinite loop?

Press the Alt key together with the Q key.

Press the Control key together with the C key.

Press the Control key together with the Q key.

Press the Alt key together with the C key.

Answers

Answer:Control +c

Explanation:yes

Answer: Press the Control key together with the C key.

Explanation: Correct on Edg 2020/2021.

An archiving department is responsible for issuing permissions for use of historical film footage.

Answers

Answer:

true

Explanation:

just finished the assignment.

Kerri uses a photo editing program a lot. To increase her productivity, she should_____.


delete it from the Start menu

put it in her My Documents folder

move the program to the desktop

create a shortcut for it on Quick Launch

Answers

Answer:

Move the program to the desktop

Explanation:

It will be easier to access and quicker to open.

colour statement is used for setting .................... and .................. colors​
(a) screen,Paint (b) line,circle
(c) foregroung,Background
(d) none of these

Answers

Answer:

The answer to this question is given below in the explanation section.

Explanation:

The correct answer to this question is C. i,e, foreground, and background.

First, we need to know what is a color statement.

The purpose of the color statement is to select display colors. It is used to select the foreground and background colors of the display.

So, the correct answer is :

Colour statement is used for setting foreground and background colors.

In general, it allows you to select foreground and background colors for a display. You can use different codes to display and see the effect of the color statement.  

While other options are not correct, because the color statement used to select foreground and background color for the display. It does not use for setting screen and paint color in it. It also does not use for drawing lines and circles etc.

How do you code a website?

Answers

Answer:

Learn the basics of HTML.

Understand HTML document structure.

Get to know CSS selectors.

Put a CSS stylesheet together.

Get Bootstrap.

Pick a design.

Customize your website with HTML and CSS.

Add content and images.

Explanation:

what is the main difference between a search bar and a web browser

Answers

Answer:

i think a search is search bar is looking for application and files that are in the system while web browser is for searching things that are not in ur pc or laptop but searching thing i a good example google

Ask the user to enter a name. If there is an ‘a’ in the name, print the message saying ‘The name contains at least one ‘a.’ If there is no ‘a’ then print “The name does not contain the letter a.”

Answers

name = input("Enter your name: ")

if "a" in name:

   print("There's at least one 'a'")

else:

   print("The name does not contain the letter a.")

I wrote my code in python 3.8. I hope this helps!

can some one help me i do not now how to give a BRANLEST. if you help i will give you one BRANLEST.

Answers

Answer:

check your questions on your profile ✨

Answer:

Once there are two answers to your question, you look at them, and in the bottom right corner, you will see a crown press that good luck! :D

AI structure question. Please help
Type the correct answer in the box. Spell all words correctly.


On what structure is an artificial neural network based?


An artificial neural network is based on interconnected _______.

Answers

Answer:

A). An ANN is based on a collection of connected units or nodes called artificial neurons, which loosely model the neurons in a biological brain. Each connection, like the synapses in a biological brain, can transmit a signal to other neurons.

B). Understanding an Artificial Neural Network (ANN)

Artificial neural networks are built like the human brain, with neuron nodes interconnected like a web. The human brain has hundreds of billions of cells called neurons.

Explanation:

Answer:

The answer to this question is Neurons

Explanation:

I took the test on Plato and got a 100%.

(Java) Meadowdale Dairy Farm sells organic brown eggs to local customers. It charges $3.25 for a dozen eggs, or 45 cents for individual eggs that are not part of a dozen. Write a program that prompts a user for the number of eggs in the order and then display the amount owed with a full explanation using the following wording: You ordered 27 eggs. That’s 2 dozen at $3.25 per dozen and 3 loose eggs at 45 cents each for a total of $7.85.

import java.util.Scanner;
class Eggs {
public static void main(String[] args) {
// Write your code here

}
}​

Answers

import java.util.Scanner;

public class Eggs {

   

   public static void main(String[] args) {

       Scanner scan = new Scanner(System.in);

       System.out.println("How many eggs?");

       int eggs = scan.nextInt();

       int dozens = eggs / 12, ind = eggs - (dozens*12);

       

       System.out.println("You ordered "+eggs+" eggs. That's "+dozens+" at $3.25 per dozen and "+ind+" loose eggs at 45 cents each for a total of $"+((dozens*3.25)+(ind*0.45))+".");

   }

   

}

I hope this helps!

In this exercise we have to use the knowledge of the JAVA language to write the code, so we have to:

The code is in the attached photo.

So to make it easier the JAVA code can be found at:

import java.util.Scanner;

public class Eggs {

  public static void main(String[] args) {

      Scanner scan = new Scanner(System.in);

      System.out.println("How many eggs?");

      int eggs = scan.nextInt();

      int dozens = eggs / 12, ind = eggs - (dozens*12);

System.out.println("You ordered "+eggs+" eggs. That's "+dozens+" at $3.25 per dozen and "+ind+" loose eggs at 45 cents each for a total of $"+((dozens*3.25)+(ind*0.45))+".");

  }

}

See more about JAVA at brainly.com/question/2266606

Which function is used to add a range of cells? =SUM =AVERAGE =MAX =ADD

Answers

Answer:

=SUM

Explanation:

The function used to add a range of cells is =SUM. Thus, option A is correct.

What is a function in excel?

Functions are pre-written formulas that carry out calculations by utilising unique values, referred to as inputs, in a given order, or layout. Calculations of any complex variable can be carried out using functions. the purpose for which a human, thing, or both are created, expressly designed, or employed.

Values are added by the SUM function. Users can include specific values, cell references, specific ranges, or a combination of all three. F

Excel's AutoSum feature makes summing up several items in an quick and simple manner. The Alt+= button makes using the AutoSum command much quicker. It can be found on the Homepage or Formulas tabs.

Therefore, option A is the correct option.

Learn more about Functions , here:

https://brainly.com/question/21145944

#SPJ6

which gallery will allow a user to access a variety of preconfigured formatting styles for images that are added to a PowerPoint presentation

Answers

Answer:

Picture Effects gallery.

Explanation:

PowerPoint application can be defined as a software application or program designed and developed by Microsoft, to avail users the ability to create various slides containing textual and multimedia informations that can be used during a presentation. Some of the features available on Microsoft PowerPoint are narrations, transition effects, custom slideshows, animation effects, formatting options etc.

To format an image on PowerPoint, you can either use the Artistic Effects or Picture Effects.

The Picture Effects gallery allows a user to access a variety of preconfigured formatting styles for images that are added to a PowerPoint presentation.

Basically, the Picture Effects consist of the following preconfigured formatting styles; transparent shadow, soft edge, reflection, glow, 3-D rotation, metal frame, bevels, perspectives etc.

Answer: Picture Styles gallery

Explanation: He is correct he just typed it wrong.

Your company works with organizations located in other countries. What is this an example of

Answers

Answer:

Globalization

Explanation:

When other countries work with other firms, international trade which is on a global scale is taken into consideration, allowing goods and services to trade between each other.

Answer:

Globalization

Explanation:

what is the computer?​

Answers

Answer:

an electronic machine that can store, find and

who got houseparty and tryna play uno

Answers

Answer:

awww shiiiii yessss

Place the steps in order for placing a section break

Answers

Answer:

choose a break option, select breaks, click the layout tab, change the formatting style, and position the cursor

Explanation:

i could be wrong cause i dont know what its about but this is what makes sense to me

Answer:

position the cursor click the layout tab select breaks choose a break option change the formatting style

Explanation:

Just had this question

Why is it important to turn a filter off when you have found what you are looking for?

A. The items the filter finds will be deleted from Outlook,
B. The filter will keep looking for items based on the criteria.
C. The filter only works in the background when it is turned off
D. The items that were filtered out, including new items, are not visible,

Answers

I think it’s D

Hope it helps :)

Answer:

D -- The items that were filtered out, including new items, are not visible.

Explanation:

Just took the test, hope this helps! :)

Select all actions you should take to check for mistakes in your formulas.

1. Check that you entered the correct data.
2. Look to see that you used the correct cell names.
3. Recalculate everything using a calculator.
4. Run a formula checker.
5. Make sure you have followed the correct order of operations.
6. Check that you used the correct operations.
7. Estimate the answer and compare to the actual answer.

Answers

Answer:

The correct options is;

Run a formula checker

Explanation:

In order to check if there are mistakes in a formula, the Error Checking dialogue box which is a tool that enables a user to rapidly detect and correct errors in formulas, can be made use of to both simplify, expedite, and streamline the process

The Error Checking dialogue box has the following commands controls;

Help on This Error; The control button brings up the help window in Microsoft Excel

Show Calculation Steps; The control starts the Evaluate Formula dialog box from which the effect of the data input values, operators and result of each step can be seen

Ignore Error; The button allows an error to be ignored

Edit in Formula Bar; Allows for the input into the formula in the Formula Bar which is much easier than editing the formula in the cell

Options; The command allows the user to view the Microsoft Excel dialog box menu

Answer:

Run a formula checker. ✔

Check that you used the correct operations. ✔

Check that you entered the correct data. ✔

Explanation:

Got it right on Edge 2022.

Other Questions
Explain what a political, economic, and social effect is. The points (3,-2) and (2,1) are both solutions to which inequality Write the equation of the quadratic function whose graph passes through [tex](-3,2)[/tex], [tex](-1,0)[/tex], and [tex](1,6)[/tex]. Read the paragraph.Violence in video games is essentially to blame for violence in our society. When children are bombarded with monstrous images, they begin to think that these types of actions are normal or acceptable. Children and teenagers are spending excessive numbers of hours playing video games, and they may begin to use them as a guideline for how to act and behave. Even if they do not perform violent actions, they may become less sensitive to the thoughts and feelings of others because of what they see reflected in these games.Which phrase best explains the kind of words the writer uses to affect the reader? How can you find directions using satellite orbiting? Mrs. Lopez bought 6 rosebushes at Lowes for $22.08. What is the unit cost of one rosebush? after moving east, nick carraway, the narrator, had this type of pet for a few days. a. dog b. cat c. fish d. bird In early America, the Navigation Acts ensured all imported products came from England. What type of market structure is this anexample of? 10 lbs to 6 lbs need percentageplease give step by step The figure was created by repeatedly reflecting triangle NMP. A figure is created by continuously reflecting triangle N M P. The length of side N M is 6 inches, the length of side M P is 4 inches, and the length of side N P is 8 inches. What is the perimeter of the figure? 36 in. 42 in. 44 in. 48 in. 3x = 8 3x + y = 15??? Select all that apply.Mohenjo-Daro and Harappa were known for _____.A. their sanitation systemsB. their large fortressesC. the grid pattern of their streetsD. their military What is the most abundant element on Earth?A oxygenB CobaltC CarbonD Iron5Any substance represented by a chemical formulaA Homogenous mixtureB Heterogenous MixtureC elementsD pure substance how has the meaning of the secound amendment changed over time What is the solution to the system of equations graphed below?On a coordinate plane, 2 lines intersect at (2, - 3).(2, - 3)(- 3, 2)(- 2, 3)(3, 2) Rico represents the inequality Negative 3 (StartFraction 8 over x minus 5 EndFraction greater-than negative 16) with the sentence "The product of 3 and the quotient of 8 and the difference of a number and 5 is at least 16." Which describes Rico's error? Write a story that clearly illustrates the saying do not count your chicken before they are hatched For all x in the domain of the function (x+1)/(x^3-x) this func-tion is equivalent to What is the value of 12 (2b-4) when b=16 Please select the word from the list that best fits the definitionBrings dry, clear weather