answersLogoWhite

0

#include<iostream.h>

void main()

{

double sum=0,avg,max=0,min=100,temp[12];

char *Month[]={"Jan", "Feb", "Mar", "Apr", "May",

"Jun","Jul", "Aug", "Sep", "Oct", "Nov", "Dec"};

for(int j=0;j<12;j++){

cout << "Enter the temperature of month :"<<*(Month+j)<< endl;

cin >> temp[j];

sum=sum+temp[j];

}

avg=sum/12;

for(int i=0;i<12;i++){

if(temp[i]>max)

max=temp[i];

if(temp[i]<min)

min=temp[i];}

cout << "Average temperature of the year: " << avg << endl;

cout << "Maximum temperature of the year: " << max << endl;

cout << "Minimum temperature of the year: " <<min << endl;

}

User Avatar

Wiki User

15y ago

What else can I help you with?

Related Questions

What is maximum minimum temperature?

the minimum temperature is -273 degree centigrade


What is the maximum temperature for a retail store by law?

there is no maximum temperature only a minimum.


What is Uranus' minimum and maximum temperature?

Ave/max temperature: -200&deg;C Minimum temperature: -214&deg;C


How do you calculate the maximum and minimum possible for total mass?

minimum is less


Delhi's maximum and minimum temperature on 1st June 2010?

maximum-42 minimum-26


How do you calculate length of the scale in a thermometer when the temperature is given?

To calculate the length of the scale in a thermometer for a given temperature, you first need to determine the range of temperatures the thermometer measures. Then, find the specific temperature's position based on the scale's total length and the minimum and maximum temperatures. Use the formula: ( \text{Length at given temperature} = \left( \frac{\text{Given Temperature} - \text{Minimum Temperature}}{\text{Maximum Temperature} - \text{Minimum Temperature}} \right) \times \text{Total Length} ). This will give you the length corresponding to the specified temperature on the scale.


Will the minimum an maximum temperature always be equidistant from the current temperature?

Not necessarily. The minimum and maximum temperature can vary and may not always be equidistant from the current temperature. The difference between the current temperature and the minimum or maximum temperature depends on various factors such as weather conditions and time of day.


The maximum and minimum temperature of earth?

765


Examples of how to calculate minimum maximum inventory level?

Minimum: (AMU/30.4)*(Leadtime*SafetyStock) Maximum is the Difference between the Minimum and Buy Qty


What are the maximum and minimum temperatures in Iraq?

in Iraq the temperature's maximum point is about 70 degrees and the minimum is about 0-10


Is there absolute maximum temperature like absolute zero minimum temperature?

No.


What is the maximum and minimum temperature for Saturn?

The maximum temperature on Saturn is around 134 degrees Celsius (273 degrees Fahrenheit) at the top of its clouds, while the minimum temperature is approximately -185 degrees Celsius (-300 degrees Fahrenheit) in its upper atmosphere.