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
Irina18 [472]
3 years ago
7

JAVA

Computers and Technology
1 answer:
avanturin [10]3 years ago
3 0

Answer:

   public ArrayList onlyBlue(String[] clothes){

       ArrayList<String> blueCloths = new ArrayList<>();

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

           if(clothes[i].equalsIgnoreCase("blue")){

               blueCloths.add(clothes[i]);

           }

       }

       return blueCloths;

   }

Explanation:

  • Create the method to accept an Array object of type String representing colors with a return type of an ArrayList
  • Within the method body, create and initialize an Arraylist
  • Use a for loop to iterate the Array of cloths.
  • Use an if statement within the for loop to check if item equals blue and add to the Arraylist.
  • Finally return the arrayList to the caller
You might be interested in
An employee is working on building a new computer application for a friend. For this purpose, he uses the software that is regis
andrezito [222]

Answer: USed software

Explanation:

5 0
3 years ago
⦁ ¿Cuáles son los recursos naturales que se utilizan en tu comunidad para generar energía eléctrica?
xxTIMURxx [149]
Turbinas de viento y turbinas de agua son utilizadas, entonces la respuesta podria ser viento y agua
7 0
3 years ago
Mechanisms that can be used to rescue accident victims
stiks02 [169]

Answer:

Hydraulic rescue tools

6 0
2 years ago
Another pitfall cited in Section 1.10 is expecting to improve the overall performance of a computer by improving only one aspect
Alexandra [31]

Answer:

<u>note:</u>

<em><u>solution is attached in word form due to error in mathematical equation. furthermore i also attach Screenshot of solution in word due to different version of MS Office please find the attachment</u></em>

Download docx
8 0
4 years ago
Most operating systems today primarily use a ____.
LenKa [72]
Screen made of pixels? Right?
3 0
4 years ago
Other questions:
  • Which of the following is an example of new and emerging classes of software?
    11·2 answers
  • Windows 7 is used to run ____ software
    5·2 answers
  • geoffrey is on location for a long shoot. he is worried that the battery power in his camera will not last. which source can he
    5·1 answer
  • As a graphic designer, you'll refer to a line as which of the following? A. Point B. Border C. Rule D. Frame
    9·2 answers
  • Over the past few years a very definite need has arisen in the electrical trades for:
    15·1 answer
  • Explain how devices on a lan access resources in a small to medium-sized business network.
    15·1 answer
  • PLEASE HELP!!!
    12·1 answer
  • What allows customers to use the Web to find answers to their questions or solutions to their problems?
    5·2 answers
  • OoooA,SDHVAcgacxgjcaNASAW dysdyxsgcdsgjsdgc
    8·2 answers
  • What report provides data on how specific sections of a website performed?
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!