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
Hot components or sharp edges of computer is an example of what hazard​
Alexxandr [17]

Answer:

hot components or sharp edges of computer is an example of a mechanical hazard

6 0
3 years ago
How long would it take a 8 bit computer to calculate π to the thousandth place?
allochka39001 [22]
The average speed of an 8 bit computer is 0.50 MIPS or million instructions per second. There are three  thousand instructions per digit of the number in <span>π, the thousandth place needs 4 x 3 = 12 thousand instructions. The time it takes to do this is 12000 / (0.5 x 1000) = 24 seconds.

</span>
7 0
4 years ago
What is the name of the computer through which e-mail messages are sent and received?
nalin [4]
A mail server. --------------------------------------------
8 0
3 years ago
You are the administrator for the contoso.com website. recently, the server hosting the website had a failure that caused it to
Alisiya [41]
Protecting the Power supply
Adding disk Arrays
Install an NLB Cluster
4 0
3 years ago
How can I change my username here at brainly?
velikii [3]

Answer:

Explanation:

LOG OUT AND CHANGE IT

3 0
3 years ago
Read 2 more answers
Other questions:
  • If you're sending an email from your laptop to a classmate the laptop is the
    11·1 answer
  • . Given an initially empty stack s that accepts integers, the following operations are performed: s.push (10) s.push (20) s.push
    13·1 answer
  • Look up and list the number of a local taxi or car service in your community. Include the company name and telephone number.
    13·1 answer
  • You can use RWA to demonstrate how to do something special on the web, such as displaying articles found on websites that suppor
    15·1 answer
  • Write the definition of a function printAttitude , which hasan int parameter and returns nothing. The function prints amessage t
    13·1 answer
  • I need someone to transfer this into a database in excel Please help :D 7 pts
    15·1 answer
  • In an array based implementationof a queue a possible solution to dealing with the full condition is to
    14·1 answer
  • I need help with this plz question 2 and 3 asap
    7·1 answer
  • Write a program in qbasic to accept a character and check it is vowel or consonant​
    14·1 answer
  • 30 points Fill in the blanks,<br> Plz leave a explanation
    5·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!