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
julsineya [31]
3 years ago
12

"Write a class named Car that has the following data attributes:" _ _year_model (for the car’s year model) _ _make (for the make

of the car) _ _speed (for the car’s current speed)
Computers and Technology
1 answer:
UkoKoshka [18]3 years ago
6 0

Answer:

public class Car {

   private String __year_model;

   private String __make;

   private int __speed;

   //Creating the constructor

   public Car(String __year_model, String __make, int __speed) {

       this.__year_model = __year_model;

       this.__make = __make;

       this.__speed = __speed;

   }

   //Creatining the set and get methods

   public String get__year_model() {

       return __year_model;

   }

   public void set__year_model(String __year_model) {

       this.__year_model = __year_model;

   }

   public String get__make() {

       return __make;

   }

   public void set__make(String __make) {

       this.__make = __make;

   }

   public int get__speed() {

       return __speed;

   }

   public void set__speed(int __speed) {

       this.__speed = __speed;

   }

}

Explanation:

As stated in the question, The class Car is created using Java programming language with the three attributes year_model, make and speed.

Constructors as well as set and get methods were also created for each of the fields.

You might be interested in
The 'client area' of a window is the area used to display the contents of the window (thus a title bar or border would lie outsi
Lady_Fox [76]

Answer:

<u>Window.java</u>

  1. public class Window {
  2.    int width;
  3.    int height;
  4.    public Window(int width, int height){
  5.        this.width = width;
  6.        this.height = height;
  7.    }
  8.    public int getWidth(){
  9.        return width;
  10.    }
  11.    public int getHeight(){
  12.        return height;
  13.    }
  14.    public int getClientAreaHeight(){
  15.        return getHeight();
  16.    }
  17. }

<u>Main.java</u>

  1. public class Main {
  2.    public static void main (String [] args) {
  3.        Window win1 = new Window(12, 15);
  4.        System.out.println(win1.getClientAreaHeight());
  5.    }
  6. }

Explanation:

<u>Window.java</u>

There is a Window class with two int type attributes, width and height (Line 1 - 3).

The constructor of this class will take two inputs, width and height and set these input to its attributes (Line 5 - 8). There are two methods getWidth and getHeight which will return the value of attributes width and height, respectively (Line 10 - 16).

The required new method getClientAreaHeight is defined in line 18 -20. This method will call the getHeight method to return the height value of the window (Line 19).

<u>Main.java</u>

We test the Window class by creating one Window instance and call the getClientAreaHeight method and print the return output (Line 1 -6).

We shall see 15 is printed.

4 0
3 years ago
. :
Rudik [331]

Answer:

Yes.  I completely agree.

Explanation:

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

Yes.  I completely agree.

7 0
3 years ago
What single word could be used to describe the importance of software design??
Eddi Din [679]
<span>abstraction possibly </span>
5 0
3 years ago
What is the best software for game design
riadik2000 [5.3K]

The 2D Design Engines

10. Sploder

This program should be labeled a product for the very novice of game designers and developers. It features a very simple interface that can be used to make shooters and platformers. The custom game, which Sploder creates, always comes out as flash, which is arguably one of the best places to start anyway. It features a drag and drop interface, and your games can also be shared with other Sploder users, making it a community application.

9. RPG Maker XP

Yet another beginner program RPG Maker is well known all around the gaming community as an awesome place to start designing. It features many tropes of those old 16bit RPG games that were in the rage during the early 90’s. Along the way, the program usually holds your hand through the process of creating your world and story, which is also supplemented by countless FAQs and forums discussing the program.

8. Multimedia Fusion 2

For the fledgling designer who has more than a few games under their belt, Multimedia Fusion 2 is the next logical step in design. It contains and intricate system that details a lot of design when it comes to levels, characters, and actions. The design also allows for easy assignment of behaviors to objects, as everything can be done through dragging and a little bit of event planning. Overall, this is a powerful program that any designer should try out in the long run.

7. Construct Classic

Construct Classic shares a lot of the same tropes with easy to use designing software in that it is very easy to use. The classic version of this program boasts the ability to create Direct X titles with the addition of an awesome physics engine, even system, and fully realized pixel shader effects. The program is ideal for creating prototypes, but can also be used to make simple games.

6. Flixel

In terms of 2D game design, Flixel reigns supreme because of one very important fact. A created game with the Flixel engine can be distributed freely, with no need to purchase a license to distribute the said game. It also got one of the most supportive forums as the program is constantly updated with improved collision and even boxes, along with countless 2D objects.

The 3D Design Engines

5. UDK (Unreal Development Kit)

The Unreal Engine is an iconic design program, and there are tons of titles that prove the very same. It has been in use for so many years that no one can dispute how powerful it really is. At the same time, it’s a very good intermediate level design program, as it features a full 3D workspace where designs for levels and characters can all be made. Be forewarned though, this is a very professional program, and if you intend to create game, you’ll have to pay $100 plus royalties for each sale.

4. Blitz Max

For beginners that want to upgrade from 2D to 3D without too many hiccups, Blitz Max is the perfect tool to translate that journey. It features a very fundamental approach to 3D games design, buy at the same time, it doesn’t restrict the user in too many ways. In terms of graphical quality, don’t expect too much out of it as the aesthetics are based on the most fundamental designs.

3. Pygame

One of the reasons why Pygame is on this list is because it deals with the Python programming language. This makes it a very big contender as Python mostly belongs the PS3 format, and is a tricky language to master. However, this program, with the many countless tutorial books makes it easier to grasp every concept required in making games.

2. XNA Games Studio

XNA is the prime language you should pick if you’re really considering getting serious with games design and creation. The design program has countless different titles under its already well established repertoire, and that is still fast growing. However, you also have to be aware that the software is on the technical side of design, as you may see in games Spelunky or Magicka.

1. Unity3D

We can’t all be masters of programming languages, and certainly, not all of us have the ability to create game engines from scratch. This is basically the idea behind Unity 3D, and it upholds that same ideal very well because it takes a very hands-off approach to your design. There are many different tutorials on how you can get started on this engine, so starting now might be beneficial to you.

7 0
3 years ago
Read 2 more answers
1. What is the relationship between liquidity and the interest rates?
Alenkasestr [34]
Liquidity Effect. When the Fed pursues a tight monetary policy, it takes money out of the system by selling Treasury securities and raising the reserve requirement at banks. This raises interest rates because the demand for credit is so high that lenders price their loans higher to take advantage of the demand.
7 0
3 years ago
Other questions:
  • Using the flowchart diagram, identifythe decision point of this solution?
    6·1 answer
  • Explain why living things store energy in lipids instead of in carbohydrates
    5·1 answer
  • When developing e-business systems, an in-house solution usually requires a ____ for a company that must adapt quickly in a dyna
    11·1 answer
  • What is the default font style of “Title” box in MS PowerPoint 2013?
    8·1 answer
  • I.d 9934607467<br> p.a.s.s 54321<br><br> P.L.E.A.S.E J.O.I.N. Z.O.0.M. M.E.E.T.I.N.G
    10·1 answer
  • The way a student prepares for a test or reviews academic material is referred to as
    8·2 answers
  • Which finger is used to press SHIFT key while typing!
    14·2 answers
  • Question 1(Multiple Choice Worth 5 points)
    9·2 answers
  • 25 points select 3 options!!!!!!!!!!!!!!!!!!!!!!!!!
    5·2 answers
  • A program that converts a program to binary all at once and runs the entire program when finished with the conversion.
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!