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
kotegsom [21]
3 years ago
15

write a function that returns a list, where each member of list contains previous day’s value multiplied by 2.​

Computers and Technology
1 answer:
sergeinik [125]3 years ago
5 0

Answer:

Explanation:

The following code is written in Java, the function takes in a list with the previous day's values. The function then uses that list, loops through it and multiplies each individual value by 2 and returns the modified list. The first red  square represents the test case for the function, while the second red square in the image represents the output.

 public static ArrayList<Integer> doubleIt(ArrayList<Integer> mylist) {

       for (int x = 0; x<mylist.size(); x++) {

           mylist.set(x, mylist.get(x)*2);

       }

       return mylist;

   }

You might be interested in
Is a component that provides a button control in a gui application or applet?
harina [27]
<span>GUI is a graphical user interface. It is a graphical window that provides interaction with the user. 
</span>The button is a pushbutton, which can be pressed to trigger an action.<span>
A graphic control component or a control element is a component that provides a button control in a GUI application. It is also called a control element because it </span><span>is an element of interaction between the user controlling the application.</span>
7 0
3 years ago
What may happen if a large number of computer users are attempting to access a web site at the same time that you are
Nitella [24]
It will most likely begin to crash and eventually just freeze , i'm guessing  
6 0
3 years ago
Read 2 more answers
If your pulse is higher than your Target Heart Rate during exercise, what should you do?
vodomira [7]
If your heart rate exceeds 185 beats per minute during exercise, it is dangerous for you. Your target heart rate zone is the range of heart rate that you should aim for if you want to become physically fit. It is calculated as 60 to 80 percent of your maximum heart rate.
8 0
2 years ago
Read 2 more answers
A cathedral hull allows the boat to do what
Hoochie [10]
It allows power boats to have stability while cruising. The cathedral hull  is like a trimaran in terehat it has one main  and two side hulls stuck together so that has a somewhat square to rectangular shape and therefore exhibits greater stability than a single hulled boat. It became more popular with the advent of fibreglass boats in the 1960's and '70s.
5 0
3 years ago
If David wishes to digitally sign the message that he is sending Mike, what key would he use to create the digital signature
Goshia [24]

The key would he use to create the digital signature is Mike public key.

<h3>Which key is used to sign messages?</h3>

Digital signatures are known to be used via public key. Here, the person is said to be one who is said to produce or creates the digital signature that  uses a private key to encrypt signature-linked data.

The only way to decrypt a data is only with the signer's public key, the key David would use to create the digital signature is Mike public key.

Learn more about  public key from

brainly.com/question/17486027

7 0
1 year ago
Other questions:
  • Write a program that loops one thousand times. add all the even numbers and display the results. add all the odd numbers and dis
    13·1 answer
  • Net Worth is equal to assets minus liabilities. Which event will have the greatest impact (positive or negative) on one's net wo
    5·1 answer
  • You are holding a rock tied to a string, which is an example of a pendulum. identify and explain the proper term for each part o
    10·2 answers
  • What is one of the most effective security tools available for protecting users from external threats?
    15·1 answer
  • Write a function named firstLast2 that takes as input an array of integers and an integer that specifies how many entries are in
    14·1 answer
  • Which field of study would be most useful for a person who wants to work in a recycling plant?
    12·2 answers
  • Muultimedia Promo try answer this question and explaining them or give examples of that topic Thanks
    10·1 answer
  • Which of the following are valid variable names? Select 2 options.
    14·1 answer
  • A profit of ₹ 1581 is to be divided amongst three partner P,Q and R in ratio 1/3:1/2:1/5.theshareof R will be?​
    10·1 answer
  • What is the value of x after running this code?
    13·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!