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
dimaraw [331]
3 years ago
9

What keyword do we use to tell Java to set aside memory to create an object?

Computers and Technology
1 answer:
Pavel [41]3 years ago
5 0

Answer: You reserve memory locations for an array when you _____.

use the keyword new

You might be interested in
Businesses around the world all need access to the same data, so there
Alexxx [7]

Answer:

B

Explanation:

3 0
2 years ago
rite a function to prompt the user to enter the information for one movie (title, release date, mpaa rating and number of stars)
vesna_86 [32]

Answer:

import java.util.*;

public class Movie {

   

   public static void main (String [] args) {

       

       System.out.println(movieInfo());

       

   }

   public static String movieInfo() {

       Scanner input = new Scanner(System.in);

       Scanner input2 = new Scanner(System.in);

       

       System.out.print("Enter the title: ");

       String title = input.nextLine();

       System.out.print("Enter the release date: ");

       String releaseDate = input.nextLine();

       System.out.print("Enter the mpaa rating: ");

       double mpaaRating = input2.nextDouble();

       System.out.print("Enter the number of stars: ");

       double numberOfStars = input2.nextDouble();

       

       return "Title: "+title+ "\nRelease Date: "+releaseDate+ "\nMPAA Rating: "+ mpaaRating+ "\nNumber of Stars: "+numberOfStars;

   }

}

Explanation

- Create a function called <em>movieInfo()</em> that returns a string, information about a movie

- Ask the user to enter the title, release date, mpaa rating and number of stars of the movie.

- Return these values at the end of the function

- Inside the main, call the function to see the information about the movie

7 0
3 years ago
Why is the Singleton pattern commonly referred to as an “anti-pattern”?
snow_lady [41]

Answer:

Singleton pattern is the pattern for design that is build using the global variables which creates a lot of drawback in the designing. Singleton pattern are considered with the global variable and thus cannot be bound into single unit which complexes the components in design.

They have a loose coupled variables in design and also does not show the property of the multi-threading .These feature are responsible for the decrement in the performance and thus are not highly preferred choice for the pattern.So, it is known as the "anti- pattern".

3 0
4 years ago
Write a note on secondary storage​
slega [8]

Answer:  Storage devices are non-volatile devices. That means that when the power is removed from them, for example, when you switch your computer off, they retain their contents (unlike RAM, which is volatile – it loses its contents). You can then retrieve the contents next time you switch your computer on. Storage devices can be used to hold operating systems, applications and files, amongst other types of software. They are simply big suitcases – used only for storage. We have already seen that when you want to use an application kept on a storage device, it has to be moved to RAM before you can start using it. This applies to the operating system, your files and any other category of software. For this reason, RAM is sometimes known as Primary Memory whereas storage devices are often referred to as Secondary Storage devices.

8 0
3 years ago
State five differences between selecting and highlighting ​
exis [7]

Answer: The difference between highlighting the text and selecting the text is highlighting is when you change the highlight/back color of the text and selecting is when you temporarily highlight it to change a certain part.

Explanation:

5 0
3 years ago
Other questions:
  • What are the differences between levels 1, 2 and 3 cache memoroes??
    8·1 answer
  • A customer struggles with the small print of most smartphones. The customer still likes the idea of using a smartphone for phone
    9·2 answers
  • You can access various sites on the WWW by using hyperlinks or by
    14·1 answer
  • What are the factors affecting the purchasing decision for dbms software?
    7·2 answers
  • If we want to access files located in a directory on a remote server, which of these options would we use?
    9·2 answers
  • A student will not be allowed to sit in exam if his/her attendance is less than 75% .
    8·1 answer
  • Website designers work on the code and programming of a website, not the style or layout of the site.
    9·1 answer
  • An administrator has been asked to update a flow that was created as part of a recent update. When the administrator opens the f
    14·1 answer
  • In two-dimensional arrays, the _____________ is always listed second.
    6·1 answer
  • Would it be feasible to combine fixed length field and variable length field format in single disk
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!