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
Reil [10]
3 years ago
15

Write a for loop that iterates from 1 to numbersamples to double any element's value in datasamples that is less than minvalue.

Ex: If minval = 10, then dataSamples = [2, 12, 9, 20] becomes [4, 12, 18, 20] function datasamples = AdjustMinValue (numbersamples user Samples minValue) % numbersamples: Number of data samples in array datasamples % data Samples User defined array % minValue: Minimum value of any element in array % Write a for loop that iterates from 1 to numbersamples to double any element's % value in dataSamples that is less than minvalue data Samples = user Samples; end
Computers and Technology
1 answer:
CaHeK987 [17]3 years ago
4 0

Answer:

function dataSamples=AdjustMinValue(numberSamples, userSamples, minValue)

dataSamples=userSamples;

%for loop

for i=1:numberSamples

%checking if dataSamples value at index,i

%is less than minValue

if dataSamples(i)<minValue

%set double of dataSamples value

dataSamples(i)= 2*dataSamples(i);

end

end

end

Explanation:

The given code is in MATLAB.

You might be interested in
What two things should you do before starting the design process
Charra [1.4K]

Answer: B and C

Explanation: Analyze the audience

                      Identify the problem

8 0
3 years ago
Although there are three well-known operating systems, the most common are Microsoft Windows and Mac OS. Discuss the similaritie
tiny-mole [99]

Answer:

There are very few similarities beyond some convergent features of their respective user interfaces. Their internal architecture is very different, differing from kernel models to shell integration to executable formats. A comprehensive list of similarities is neither possible nor useful, because it would consist mostly of obvious statements like "They are both operating systems" or "They both have graphical user interfaces, "They both include

Explanation:

How's that?

7 0
2 years ago
What are the two main charaters from maid sama?
Gennadij [26K]

Answer:

Takumi Usui and Misaki Ayuzawa

Explanation:

don't know why this is here

8 0
3 years ago
Read 2 more answers
Historically, development of a new technology often:
andrew-mc [135]

Answer:

2. Leads to increases in productivity only once firms learn how to use it.

Explanation:

Technology is an all new or improved way of doing things to enhance effectiveness and efficiency that will lead to increase output. But the new technologies can not improve a business output if they don't grow with the trend of new technologies by updating their knowledge regularly

7 0
3 years ago
Read 2 more answers
How the average temperature changes in the first 5 months of the year
const2013 [10]
If you could specify the temperature of what you need would be better, like the temperature of the earth or such. But from what I can guess is that temperature changes because of the Earth's tilt and revolution around the sun causing seasons and the moon orbiting the earth which cause the day and nights we experience.

hope this benefits at least a portion of your question
6 0
3 years ago
Other questions:
  • True or false words spelling and grammar check is always %100
    7·2 answers
  • You can install several printers on your machine, but at least one must be the _______ printer.
    6·1 answer
  • What was one of the first inventions that made it possible to communicate almost instantly?
    11·1 answer
  • Turning up the transmit power or utilizing a high gain antenna to reach wireless users from a distance increases your exposure t
    12·1 answer
  • which three objects can be linked or embedded in a word document? A. worksheets, margins, colors B. charts, worksheets, images C
    7·1 answer
  • Consider the following high-level recursive procedure: long long int flong long int n, long long int k long long int b b k+2; if
    9·1 answer
  • Data-as-a-service began with the notion that data quality could happen in a centralized place, cleansing and enriching data and
    7·1 answer
  • What is a thoughtware​
    7·1 answer
  • If a person communicates indirectly and attaches little value to
    6·1 answer
  • Question #1
    13·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!