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
Ivenika [448]
4 years ago
9

Create a method called fixArray(int[][] array, int row, int col, int value) that sets the [row][column] to the correct value. Th

en, call the fixArray method three times - once for each value change that you are supposed to make.
Computers and Technology
1 answer:
PolarNik [594]4 years ago
7 0

Answer:

  1. public class Main {
  2.    public static void main (String [] args) {
  3.        int[][] myArray = {{1,5,6}, {7, 9, 2}};
  4.        fixArray(myArray, 1, 2, 12);
  5.        System.out.println(myArray[1][2]);
  6.    }
  7.    private static void fixArray(int[][] array, int row, int col, int value){
  8.        array[row][col] = value;
  9.    }
  10. }

Explanation:

The solution code is written in Java.

Firstly, create the method fixArray with that takes four inputs, array, row, col and value (Line 11). Within the method body, use row and col as index to address a particular element from array and set the input value to it (Line 12).

Next, we test the method in the main program using a sample array (Line 4) and we try to change the row-1 and col-2 element from 2 to 12 (Line 5).

The print statement in Line 7 will display 12 in console.

You might be interested in
GIVEAWAY GIVEAWAY GIVEAWAY GIVEAWAY
Maru [420]

Answer:

Alice Coltrane

Explanation:

6 0
3 years ago
Read 2 more answers
A hotspot is a location where
Andrej [43]
D is the answer you’re looking for
6 0
3 years ago
Read 2 more answers
What?<br> I couldn't hear you.<br> (play along)
nexus9112 [7]

Answer:

no

Explanation:

5 0
3 years ago
Using Windows CMD, how would an attacker list all the shares to which the current user context has access?
Lapatulllka [165]

Answer:

NET USE

Explanation:

The windows CMD is a command line interface or terminal used to access information about the system. The CMD can be also used to rectify or troubleshoot problems in the windows environment. There are series of hard coded commands in this interface.

An attacker uses the command "NET USE" to remotely connects or disconnects a computer and can be used to list the current connections of a user's computer.

8 0
3 years ago
An ______ is a major type of KM that collects, stores, and disseminates digital content and knowledge
Luba_88 [7]

Answer:

enterprise-wide km

3 0
3 years ago
Other questions:
  • Why do all the people are mean, why report my answer even when it is correct and the reason would i have violated their terms .
    10·1 answer
  • Apache web server is the most widely used network operating system used on web servers.
    8·2 answers
  • A comma is also called a statement terminator. A. True B. False
    8·1 answer
  • A peer-to-peer (p2p) network is an example of ________ administration
    5·1 answer
  • The physical part or components of a computer system called​
    5·2 answers
  • what does it mean when my brainly just tells me theres no answers for any of my questions i have the plus and ive been using it
    8·1 answer
  • what technology is used to prove that an object is a living organism, and what is the piece of evidence used to prove that?
    14·1 answer
  • Hello everyone! can anybody help me? i need help with computing.
    10·1 answer
  • 3. How has air - conditioning affected human life?​
    15·1 answer
  • When is it appropriate to utilize the nat network connection type?
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!