computer science

posted by .

You work for a company that requires you to compute the average temperature for 8 A.M. to 6 P.PM. each day. You are to computer program to compute the average temperature.

  • computer science -

    use Util::List;
    print "Enter hourly temperatures: ";
    $_ = <STDIN>;
    @t = split;
    $avg = sum(@t)/@t;
    --------------------------
    add error checking if you wish, to watch for invalid format, or an empty list.

Respond to this Question

First Name
School Subject
Your Answer

Similar Questions

  1. Computer class

    how do I design a program using a flowchart, the program needs to compute state and county sales tax?
  2. Computer science

    Write an HTML form that prompts the user to enter loan amount, interest rate, and number of years, as shown in Figure 1. Clicking the Compute Payment button invokes a JSP program to compute and display the monthly and total loan payments, …
  3. PreCal

    A trainee is hired by a computer manufacturing company to learn to test a particular part of a personal computer after it comes off the assembly line. The learning curve for an average trainee is given by N=200/4+21e^-0.1t a)How many …
  4. PreCal - repost

    A trainee is hired by a computer manufacturing company to learn to test a particular part of a personal computer after it comes off the assembly line. The learning curve for an average trainee is given by N=200/4+21e^-0.1t How many …
  5. programming

    Write an algorithm to compute average score for each student in the Computer Science Continuous assessment test. Assume each student sat for ten courses for the semester
  6. computer programming

    Write a fortran program to compute the geometric information for a kite. The program should read the a, c and p lengths and compute the q length
  7. Computer science

    need help how do this program. Use the top-down modular approach and pseudocode to design a suitable program to solve it. Alberta Einstein teaches a business class at Podunk University. To evaluate the students in this class, she has …
  8. computer science

    how to write c++ program to compute to display natural number between 1 and 30 which are divisible by 12
  9. computer programming

    given three numbers A,B,C. draw a flowchart to compute and print out the sum, average and the product of these values.
  10. math

    Suppose the daily high temperature in a town is 3 degrees above average one day, then 5 degrees below average the next day, then 2 degrees above average, then 1 degree below average, then 6 degrees above average, then equal to the …

More Similar Questions