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

Rainfall_mi is a string that contains the average number of inches of rainfall in Michigan for every month (in inches) with ever

y month separated by a comma. Write code to compute the number of months that have more than 3 inches of rainfall. Store the result in the variable num_rainy_months. In other words, count the number of items with values > 3.0.
Computers and Technology
1 answer:
const2013 [10]3 years ago
5 0

Answer:

Hi!

The answer in Javascript is:

function monthsWithMoreOfThree() {

  var Rainfall_mi = '3,4,1,5,2,6,7,9'; <em>//Defined and declared</em>

  var num_rainy_months = 0;

  var values = Rainfall_mi.split(","); <em>//use split method for Strings. Array is returned</em>

   for (var i = 0; i < values.length; i++) { <em>//for each value, compares with 3</em>

     if(values[i] > 3) { <em>//In Javascript, you can compare an String value with an int. Can use parseInt(aString) to explicit parse but is not necessary</em>

       num_rainy_months++; <em>//If value is greater than 3, adds 1 to num_rainy_months</em>

     }

   }

}

You might be interested in
The rules that govern the correct order and usage of the elements of a language are called the of the language:.
Strike441 [17]

The syntax of a language are the rules that govern the correct order and usage of the elements of a language.

<h3>What is a programming language?</h3>

This is a set of rules that are used to send commands to a computer system as a prompt to have it perform certain tasks.

The syntax of a language are the rules that are used in that particular programming language.

Read more on syntax here: brainly.com/question/21926388

7 0
2 years ago
Can we change the format of a field (e.g. Number to Dollars).
mixer [17]

I think the answer is

3 - Usually, but we may need to convert the data types (date to text)

Because we can change the format, but depends of the original format type and in what type you need to format.

I think this can help.

3 0
4 years ago
in a mechanism ,when the input goes from a small gear to an output which is a larger gear the speed will _____
dsp73
The speed (rotations per minute) will decrease.
3 0
3 years ago
What is the treaty of paris
vova2212 [387]

The Treaty of Paris, signed in Paris by representatives of King George III of Great Britain and representatives of the United States of America on September 3, 1783, ended the American Revolutionary War. Hope this helps :)

5 0
3 years ago
Read 2 more answers
Digital information is stored using a series of ones and zeros. Computers are digital machines because they can only read inform
ryzh [129]
Is known as the binary system
8 0
3 years ago
Read 2 more answers
Other questions:
  • Anybody play apex legends? I need somebody to climb with in comp (I main octane)
    15·1 answer
  • Which camera options shows time to be slowly
    5·1 answer
  • Which of the following best meets the requirements of a strong password?
    5·2 answers
  • While these two approaches have similarities in terms of the topics they address, ________ will cover broad IT management topics
    7·1 answer
  • Which is an internet service? <br> A.) antivirus <br> B.) chat <br> C.) firewall<br> D.) router
    6·2 answers
  • a limited-access expressway. A)allows vehicles to enter or exit only at certain place.B) does not permit trucks or buses.C)has n
    9·1 answer
  • Out of a list of the values 8, 3, 30, 5, 15, and 6, what result would the MIN function return?
    9·2 answers
  • True/False - According to CP-14 Sale of Modular Homes, a licensee who sells land and a modular home to be affixed to the land, t
    11·1 answer
  • The distance between two walls is called what?
    8·2 answers
  • Hurry please I’ll give Brainliest if you are right
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!