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
Ket [755]
3 years ago
10

Write a method named removeRange that accepts an ArrayList of integers and two integer values min and max as parameters and remo

ves all elements values in the range min through max (inclusive). For example, if an ArrayList named list stores [7, 9, 4, 2, 7, 7, 5, 3, 5, 1, 7, 8, 6, 7], the call of removeRange(list, 5, 7); should change the list to store [9, 4, 2, 3, 1, 8
Computers and Technology
1 answer:
telo118 [61]3 years ago
5 0

Answer:

Answered below

Explanation:

public ArrayList<Integer> removeRange(ArrayList<Integer> X, int min, int max){

int i; int j;

//Variable to hold new list without elements in //given range.

ArrayList<Integer> newList = new ArrayList<Integer>();

//Nested loops to compare list elements to //range elements.

if(max >= min){

for( i = 0; i < x.length; I++){

for(j = min; j <= max; j++){

if( x [i] != j){

newList.add( x[i] );

}

}

}

return newList;

}

}

You might be interested in
True or false A thesaurus is a brunch of commands grouped together as a single command used to automate task
Nina [5.8K]

False a thesaurus are a list of synonyms or antonyms

4 0
3 years ago
Write the code to call a function named send_variable and that expects a single int parameter. Suppose a variable called x refer
NemiM [27]

Answer:

<em>#include <iostream></em>

<em>using namespace std;</em>

<em>//function definition</em>

<em>void send_variable(int num){</em>

<em>    cout<<"The Number is "<<num<<endl;</em>

<em>}</em>

<em>// main function begins here</em>

<em>int main()</em>

<em>{</em>

<em>    int x =15; //declares an it variable and assigns 15</em>

<em>    // Calls the function send_variable</em>

<em>    send_variable(x);</em>

<em>    return 0;</em>

<em>}</em>

Explanation:

Using C++ programming language we created the function called send_variable and in the main function we call this function which only displays the value of an int variable passed unto it.

6 0
3 years ago
Which of the following might be appropriate to be created as a constant variable?
jasenka [17]

Answer:

Number of feet in a mile

Explanation:

In this problem, we need to find an option that to be created as a constant variable.

In option (a) "number of feet in a mile".

As 1 mile = 5280 foot

The number of feet in a mile is constant in every condition.

In option (b), (c) and (d)

number of people inside a store , current grade in a class , score in a football game are no fixed. It is not created as a constant variable.

Hence, the correct option is (a).

7 0
3 years ago
Password ____ traverse the network searching for passwords from remote authentication systems.
irga5000 [103]

The correct answer is scanners.

<h3>what is password?</h3>

A password is a group of letters and numbers that is used to confirm a user's identity throughout the authentication process. Passwords are frequently used in conjunction with usernames; they are created to be known only by the user and grant access to a device, application, or website on their behalf. Letters, numbers, and special characters can all be used in passwords, and their length can vary.

When a password contains more than one word, it may be referred to as a passphrase. When a password contains solely digits, such as a personal identification number, it may be referred to as a passcode or passkey (PIN).

learn more about password refer:

brainly.com/question/15569196

#SPJ4

3 0
2 years ago
Suppose that we time three functions in Python: linear searching, binary searching, and sorting. We determine their running time
Igoryamba

Answer:

134

Explanation:

because 6.00×10-9 =51 and 1.80×10-8=10 and 8.00×10-7=73 by adding them it will give the answer out by the figuer 134

6 0
3 years ago
Other questions:
  • Suppose that cells B1 through B100 of an Excel spreadsheet contain the quantity of units ordered on each of 100 different days.
    13·1 answer
  • To put out a minor engine fire, use
    12·1 answer
  • What is the purpose of interrupts? How does an interrupt differ from a trap? Can traps be generated intentionally by a user prog
    11·1 answer
  • Linela Insurance needs to hire twenty accountants immediately to support its accounts receivable process. The hiring and trainin
    7·1 answer
  • Which is better computer science or software engineering?
    10·2 answers
  • Write a C function which takes three parameters which are the cost for an item in a grocery store, the quantity to buy, and the
    12·2 answers
  • The purpose of a flowchart is similar to the purpose of pseudocode.<br> True<br> False
    5·2 answers
  • What is the value of grade after this program is executed? Assume the score is 50. if score &gt;= 90: grade = "A" elif score &gt
    5·2 answers
  • When was the first computer made?
    8·1 answer
  • The _____ feature enables you to represent text as colorful visuals.
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!