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
Paul [167]
3 years ago
6

Assume the method doSomething has been defined as follows: public static void doSomething (int[] values, int p1, int p2) { int t

emp = values[p1]; values[p1] = values[p2]; values[p2] = temp; } What does the method do? Group of answer choices
a.It inserts a new value into the array values.
b.It swaps the integer values stored in positions p1 and p2 of the array values.
c.It copies the integer array values to a new array.
d.It moves each element of the array values to a higher index position.
Computers and Technology
1 answer:
Dmitriy789 [7]3 years ago
8 0

Answer:

The answer to this question is option "b".

Explanation:

In the method definition, we perform swapping. To perform swapping we define a variable "temp" that swap values of variable p1 and p2 and store in array that is "values". and other options are not correct that can be defined as:

  • In option a, It does not insert any new value in array because we do not pass any value in function.
  • In option c, The function does not copy and assign a value in a new array because in this function we not assign any new array.  
  • In option d, It is incorrect because it can not move an element into high index position.
You might be interested in
The throws clause of a method: a. specifies the exceptions thrown by the calling method. b. specifies the exceptions a method th
Wittaler [7]

Answer:

Option B

Explanation:

8 0
3 years ago
____ is any technology that aids in gathering information about a person or organization without their knowledge.
DanielleElmas [232]

Answer:

Spyware

Explanation:

In most cases, a spywares are unwanted software enters into your computer or other devices and steal sensitive information, your internet usage data, and other information. Spyware is considered a malware type and a malicious one that is aimed at damaging a device or gaining control and access without the knowledge of the owner.

4 0
3 years ago
What is the difference between connecting link and missing link ?
JulijaS [17]
It's simple. Missing link is the connecting link which had been cut or extinct. The main example are extinct animal species.
8 0
3 years ago
I have a project on "USING ADVANCED FORMULAS". It wants me to make a spreadsheet to track payroll. I have no clue how to do this
ANTONII [103]
Try to do it on Microsoft word 2013
7 0
3 years ago
Inputs should be blue colored font and should have ________ only. process and outputs should be in black colored font and have _
maksim [4K]

Inputs should be blue colored font and should have hardcoded numbers only,  and process and outputs should be in black colored font and have  formulas only.

<h3>What does input implies?</h3>

The term input is one that connote when a thing such as power or a  signal, is known to be put into any machine or system.

Note that Inputs should be blue colored font and should have hardcoded numbers only,  and process and outputs should be in black colored font and have  formulas only.

Learn more about Inputs from

brainly.com/question/20489800

#SPJ2

7 0
2 years ago
Other questions:
  • How to add bullet points in google slides??
    12·2 answers
  • Where did the fd00::0:0:0:1 address that you supplied for the dns recursive name server ipv6 address list option come from?
    8·1 answer
  • . Here is a sequence of addresses during execution of some program: 4, 16, 0, 20, 52, 68, 172, 64 Assuming a fully associative c
    8·1 answer
  • Mark lives in an area that is prone to tornadoes. If a tornado is headed his way, what is one thing Mark should do? A. Get in hi
    8·1 answer
  • Angela recently purchased a new Android smartphone. While purchasing the phone, Angela was told that she would need to set up a
    14·1 answer
  • What are some pros for having your phone during school hours?
    10·2 answers
  • A blog is Group of answer choices a character in Lineage,
    15·1 answer
  • Papa Mario of Mario's Pizzeria has baked a huge pizza and cut it into n slices, but he is clumsy and the pizza wasn't evenly sli
    14·1 answer
  • SUMMING THE TRIPLES OF THE EVEN INTEGERS FROM 2 THROUGH 10) Starting with a list containing 1 through 10, use filter, map and su
    15·1 answer
  • _______ is the use of software to assist in the creation, analysis, and modification of the design of a component or product.
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!