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
Harman [31]
3 years ago
5

printArray is a method that accepts one argument, an arrayof int. The method prints the contents of the array; it does not retur

n a value. inventory is an array of int that has been already declared and filled with values. Write a statementthat prints the contents of the array inventory by calling the method printArray using a declared and instantiated object named obj.
Computers and Technology
1 answer:
castortr0y [4]3 years ago
8 0

Answer:

public class ArrayTest {

   public static void main(String[] args) {

       int [ ] inventoryArray = {2,34,45,65,78,78,100};

       Array obj = new Array();

       obj.printArray(inventoryArray);

       //new Array().printArray(inventoryArray);

   }

}

class Array {

   public void printArray(int []arr) {

       for(int i =0; i<arr.length; i++){

           System.out.print(arr[i]);

           System.out.print(" ");

       }

   }

}

Explanation:

  1. Two classes are created
  2. Array and ArrayTest
  3. The class Array has the method printArray that accept an argument array and prints the contents using a for loop.
  4. In the class ArrayTest, and array is created and initialized with some values called inventoryArray.
  5. An object of the Array class is created and named obj
  6. the method printArray of the Array class is called and passed the created inventoryArray. This prints the values to the screen
You might be interested in
A telephone repair technician uses a meter to measure voltage on a phone line. This meter is an example of _____.
frozen [14]
It is an example of hardware.
3 0
3 years ago
Read 2 more answers
What type of code do computers typically use to operate? A. CSS B. HTML 5 C. HTML D. Binary
Ugo [173]

Answer:

D. Binary

Explanation:

Computer hardware parts are built on transistors, small electrical devices that switch electrical signals and amplify power. The CPU (Central Processing Unit), the "brain" of the computer, has billions of tiny transistors <em>alone</em>.

These transistors read binary, a code made up of 1's and 0's. This code tells what the computer to do.

CSS, HTML, and HTML 5 apply to web pages and web page designs, not code for the computer.

The OS (operating system) that your computer runs is coded in C++ (Windows) or C (Linux)

4 0
3 years ago
Pinterest, a visual bookmarking Website, logs more than 14 terabytes of new data each day, which means its storage needs are con
Wewaii [24]

Answer:

The correct answer is option (A).

Explanation:

Pinterest has turned to amazon for storage as a service because it continuously needs a large amount of storage as given in the scenario.

While the other options are not correct because of the following reasons:

  • Grid computing can be defined as the concept of connection between a large number of computers in an architectural way who work to obtain the same goal but grid computing can not fulfill the need for storage for Pinterest.
  • Cloud computing can work as data storage which can be accessed from the internet anywhere but this can not fulfill the storage requirements for Pinterest as they are very huge.
  • Infrastructure as a service is not correct because the need of the company is for storage.

4 0
4 years ago
A derived class has access to __________.
Kitty [74]

Answer:

Option a is the correct answer for the above question

Explanation:

The derived class is a class that inherits the property of the base class, and he can access the public variable and function or members of the base class or ancestor class.

Option 'a' also states the same and the question asked about the assessment of the derived class. Hence option a is the correct answer while the other is not because:-

  • Option b states about the private members, but it is not accessible by the derived class.
  • Option c states about the derived class members but it can also access the base class members.
  • Option d none of the above, but option a is the correct answer.

5 0
4 years ago
9. which of the following cities is not considered one of the top game development hotbeds?
Kitty [74]

Answer:

9. C

10. C

Explanation:

I hope it can help

3 0
3 years ago
Other questions:
  • What was the benefit of a caloytpe over a daguerreotype
    6·2 answers
  • You friends parents are worried about going over their budget for the month. Which expense would you suggest is NOT a need?
    10·1 answer
  • PLEASE HELP
    9·2 answers
  • Which communication device uses wireless data transmission? Select 4 options.
    8·1 answer
  • Your it department enforces the use of 128-bit encryption on all company transmissions. your department also protects the compan
    13·1 answer
  • RFID tagging is an IoT technology that allows assets to be tracked using electromagnetic fields to automatically identify tagged
    10·1 answer
  • Why is it important to ensure that your software is up to date?
    13·1 answer
  • Which component of the computer keeps the operating system when the computer is running​
    10·1 answer
  • Create a class RightTriangle which implements the API exactly as described in the following JavadocLinks to an external site..
    11·1 answer
  • What is this line called that appears and disappears in the search box<br><br> WILL MARK BRAINLIEST
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!