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
____ [38]
3 years ago
14

Consider the following method intended to modify the parameter names by removing all instances of the String n.

Computers and Technology
1 answer:
Anastasy [175]3 years ago
7 0

Answer:

int i = 0; i < names.size(); i++

Explanation:

The ArrayList must be read in the forward direction, and it is going to start from 0 certainly. Also, the iteration is going to end when i is exactly one less than the size of the ArrayList. And this is possible only if we choose the option mentioned in the Answer section. In this, i starts from 0 and iterates till i is one less than name.size() which is the size of the ArrayList.

You might be interested in
What Is What is the difference between system software and application software?<br>​
inna [77]

Answer:

Hope it helps have a nice day..

4 0
2 years ago
Use the arr field and mystery () method below.
kolezko [41]

Answer:

The sum of all positive even values in arr

Explanation:

We have an array named arr holding int values

Inside the method mystery:

Two variables s1 and s2 are initialized as 0

A for loop is created iterating through the arr array. Inside the loop:

num is set to the ith position of the arr (num will hold the each value in arr)

Then, we have an if statement that checks if num is greater than 0 (if it is positive number) and if num mod 2 is equal to 0 (if it is an even number). If these conditions are satisfied, num will be added to the s1 (cumulative sum). If num is less than 0 (if it is a negative number), num will be added to the s2 (cumulative sum).

When the loop is done, the value of s1 and s2 is printed.

As you can see, s1 holds the sum of positive even values in the arr

7 0
2 years ago
State three reasons why users attach speakers to their computer​
____ [38]

Answer:

For listening sake

To listen to information from the computer

They receive audio input from the computer's sound card and produce audio output in the form of sound waves.

8 0
3 years ago
(Java) Can anyone help me with this ?? The skeleton of the code must be same as the image.
Kay [80]
Is that a essay ur supposed to write

6 0
3 years ago
2. Write a program with a function that accepts a string as an argument and returns a copy of the string with the first characte
Oduvanchick [21]

Answer:

Following are the code to this question:

def capital(val):#defining a method that takes string value as parameter

   x=True#defining boolean variable

   r=''#defining string variable  

   for i in val:#defining loop to convert the first character into upper case

       if i.isalpha() and x:#defining condition to check input value is string

           r=r+i.upper()#change value into uppercase and hold value in r variable

           x=False#assign value false in boolean variable

       elif i=='.' or i=='?' or i=='!':#check symbols

           r=r+i#add value in r variable

           x=True#assign value True in boolean variable

       else:

           r=r+i#add all value in r variable

   return r#return r variable value

val=input()#input value in val variable

print(capital(val))#called the function which print the return value

Output:

please find the attachment.

Explanation:

  • In the above python program, a method "capital" is declared, which accepts a "val" a string value in its parameter, and inside the method one boolean "x" and one string "r" variable is used, in which r stores return value.
  • In the next step, for loop is declared, inside the loop, the conditional statement is used, in if the block it checks string value and converts the first character into upper case and assigns value false in the boolean variable.  
  • In the next step, elif block is defined that adds value in r variable and at the last, it will return function value, at the last step "val" variable is declared that input value from the user and pass into the method and print its return value.

4 0
2 years ago
Other questions:
  • Which of the following is a true statement? Question 33 options: Data entities correspond to sources/sinks on a data flow diagra
    14·1 answer
  • Your client expresses that they want their new website to have a responsivedesign with consistent coding. They are concerned wit
    5·1 answer
  • How are different types of cars similar and different?
    10·1 answer
  • Mr. Perry has bookmarked a large number of webpages in Chrome while researching class topics. Unfortunately, he's bookmarked so
    13·1 answer
  • Which type of operating system is usually used in personal computers
    13·1 answer
  • Using a single formatting _______ helps to make reading researched information easier; it lets the reader know what to expect.
    7·1 answer
  • Importance of producing a hardcopy output​
    15·1 answer
  • Sites like Zillow get input about house prices from a database and provide nice summaries for readers. Write a program with two
    12·1 answer
  • Is anyone a robIox moderator?
    13·2 answers
  • Insertion point shows where the typed text will appear.
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!