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
Olegator [25]
3 years ago
12

In this problem, you will write three methods to:

Computers and Technology
1 answer:
gulaghasi [49]3 years ago
8 0

Answer:

see explaination for program code

Explanation:

program code below:

class Names{

public static String[] makeNames(String[] array1, String[] array2){

if(array1.length == 0) return array2;

if(array2.length == 0) return array1;

String[] res = new String[array1.length*array2.length];

int k = 0;

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

for(int j=0;j<array2.length;j++){

res[k++] = array1[i] + " " + array2[j];

}

}

return res;

}

public static String[] makeNames(String[] array1, String[] array2, String[] array3){

return makeNames(makeNames(array1, array2), array3);

}

public static void print(String[] array){

for(String name : array){

System.out.println(name);

}

}

public static void main(String[] args) {

String[] first = {"David", "Mike", "Katie", "Lucy"};

String[] middle = {"A","B", "C", "D", "E"};

String[] last = {};

String[] names = makeNames(first, middle, last);

print(names);

print(names);

}

}

You might be interested in
Please help me!!!
Marat540 [252]

Answer:

it is

Explanation:

8 0
3 years ago
Read 2 more answers
According to the text, what have humans used throughout history to overcome physical limits?
Alinara [238K]

Answer:

Cars  

would most likely be your answer. Because technology doesn't help with anything physical. And the other two are horse rubbish.

Explanation:

6 0
4 years ago
The general who directed the project responsible for the "Fat Man” graduated from what alma mater in 1918? Hint: W___ P____.
artcher [175]
<span>The general who directed the project responsible for the "Fat Man” graduated from : West point The fat man project refer to the codename of the atomic bomb that were dropped on top of Nagasaki in 1945. Although by dropping the bomb we did made japan surrender from the world war II, we killed more than 50,000 people with a single bombHope this helps. Let me know if you need additional help!</span>
5 0
3 years ago
When defining a class, it is a best practice to declare ____ as private. constructors mutators nothing should be private accesso
katrin [286]

Answer:

The answer is "variables".

Explanation:

It is necessary to declare a variable privately when declaring a class because the private variable 'protects' the code while it is in operation. It may not aim to protect it at this stage from changing the codes themselves for other developers. Its purpose of the so-called "data hiding" is to hold the internal data from many other classes using the class protected.

6 0
3 years ago
Given that<br>f(x) = 5x +3.<br>Find f (4)​
Vitek1552 [10]

Answer:

Given that

f(x) = 5x +3.

f (4)=5×4+3=23

3 0
3 years ago
Read 2 more answers
Other questions:
  • In the dewey decimal sysytem, the call number 800 notes which section
    10·1 answer
  • The conscious process of planning and controlling how you spend your time is called?
    15·1 answer
  • A computer programme that tells the computer how to perform particular tasks
    8·1 answer
  • Computer-aided manufacturing (CAM) offers which possible benefits?
    15·2 answers
  • Whay device is recommended to use to install windows 10
    13·1 answer
  • Which scenario could be represented by the given graph?
    14·1 answer
  • Please help! In your own words explain the difference between a problem and an algorithm.
    13·2 answers
  • A(n) _____________ changes the order in which instructions are carried out by directing the computer to execute a statement else
    12·1 answer
  • To meet the requirement for the number of vdss on board, what must be true about pyrotechnic vdss?
    15·1 answer
  • A(n) _____ is the software that enables the os to control a device.
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!