Download as doc, pdf, or txt
Download as doc, pdf, or txt
You are on page 1of 3

ADDIS ABABA SCIENCE AND TECHOLOGY UNIVERSITY

COLLEGE OF ELECTRICAL AND MECHANICAL ENGINEERING


DEPARTMENT OF SOFTWARE ENGINEERING

FUNDAMENTALS OF PROGRAMMING I

INDIVIDUAL ASSIGNMENT 1

NAME: SELAMU DAWIT

Group 5
SECTION: F
ID: ETS 0602/12
Submission date: 28/06/21
Submitted to: Instructor chere
 
Question 1
(Meteorology) Ethiopian meteorology agency wants an application that records the high and low
temperatures for each day of all months of for the year 2010.  The agency requests you to design the
application using three-dimensional weather array by which the months, days and daily (low, high,
average) temperatures represented. The months are labeled by the numbers 1 to 12, the  date of the
months are numbered 1 through 31 representing the days, and three  columns labeled H and L,
representing the day’s high, low and average  temperatures. Use this information to develop a program
that records the high and low temperatures for each day of all months and then allow the user to
request the following: 
▪ Any day’s high and low temperature. 

▪ Any month high, low and average temperatures for a given month

▪ Month and day with the highest temperature 


▪ Month and day with the lowest temperature. 

▪ All months average temperature to be printed in table format

Analysis

Input

To record data

Input month number ,which is 1-12 and day number ,which is from 1 up to 31 based on months every days
daily highest and lowest temperature in degree Fahrenheit

Output

 Highest ,lowest and average temperature of any months if the data are recorded.

 highest ,lowest and average temperature of any days if the data are recorded.

 average temperature of every months in tabular format.

 every days ,which means 365 days highest ,lowest and average temperature in tabular format.
 Month and day with the highest temperature.

 Month and day with the lowest temperature.

Operation

 Function declaration

 Variable declaration

 Print assistant menus on the screen to guide the user

 Read and store daily highest and lowest temperature ,also calculate and daily average temperature by
dividing highest and lowest value to 2 and store them in three dimensional array(3D) ,highest
temperature in column 1 lowest in column 2 and average in column 3.

 check the selected temperature value is grater than -460°F and less than 212°F

 check weather the inserted months number is between 1 and 12 ,also check the input of day is inside
day of the month interval

 Check weather data is recorded or not

 print on the screen highest ,lowest and average temperature of any days from recorded data based on
users order

 print on the screen highest ,lowest and average temperature of any moths by comparing data stored in a
selected month based on users order and show the progress of the monthly average temperature

 print on the screen the average temperature of every months in tabular format by calculating the average
temperature every months based on users order

 print on the screen every days ,which means 365 days highest ,lowest and average temperature in
tabular format from recorded data based on users order

 print on the screen Month and day with the highest temperature also Month and day with the lowest
temperature by compering whole data based on users order

You might also like