You are on page 1of 1

An-Najah National University

Department of Computer Engineering


Computer Programming 66111

Programming Assignment # 1
ILO 1


Q1: Write complete C++ program that will read three integer values x, y and z from
keyboard then compute the result of the following expressions.






Q2:write a c++ program that reads a number that represents the temperature. And it
reads the type of input temperature, F for Fahrenheit and C for Celsius. Then your
program converts from Fahrenheit to Celsius and vice versa.
Hint:
C x 9/5 + 32 = F
(F - 32) x 5/9 = C


Q3: wire a c++ program that reads the coordinates of two points x1,y1,x2,y2 and
prints the distance between these two points


Q4: write a c++ program that keeps reading integer numbers until a negative number
is entered. Then your program prints the average and the maximum of the numbers
that are divisible by 5 only.


Deadline:3/10/2013




. G0240




Good Luck
15 3 * & & 10
* 3 )% ' ' ( ) ( * 3 '% '
* 3 '% '
2 2



z y x
z y A x z y A x
z y A x

You might also like