Documente Academic
Documente Profesional
Documente Cultură
1st Term
) (
www.aymanzyan.bravehost.com
(Chapter 1)
Q1: Define an information system. Answer: An information system is the combination of technology (computers) and people that enable an organization to collect data, store them, and transform them into information. What is the difference between data and information? Answer: Data Information
Data are raw facts that are collected and stored by the information system. Information are data that converted by the information system into information
Q2:How you can convert data into information? Answer: By information system we can convert data into information. Q3:What is the difference between high level languages and machine language? Answer: High Level Languages English-like languages, they are close to the level of the programmer
Depending
Machine Language The computer understand only machine language, which is entirely composed of zeroes and ones.
on the type of language and the application, one of two methods is used for this translation process: interpretation or compilation.
Q4:What is the difference between compiler and interpreter? Answer: Compiler Interpreter
Entire program is translated Each statement has to be into machine language before converted to binary (0,1) each any attempt to execute it. time it is encountered in the program even if it has been converted previously. more difficult to find errors more easy to find errors during during compilation than during interpretation than during interpretation compilation Compiled program will run Translated program will slower faster than an interpreted than executing a compiled program. program.
Q5:Mention the main operations that all computers can perform. Answer: The main operations that all computers can perform are: 1-Input data (reading data) 2-Store data in internal memory 3-Perform arithmetic operation on data 4-Compare two values and select one of two alternative actions 5-Repeat a group of actions any number of times 6-Output the results of processing Q6:Define the variable Variable are memory location that used to store data. Q7:Why the memory location called variables? Answer: Since the values in a memory location can change as the process occurs, the memory locations are called variables. (( Chapter 2 Q8:Define the flowcharts.
4
Answer: The flowchart is a mean of visually presenting the flow of data through an information processing systems. Q9: Mention the steps for problem solving: Answer:
Define the problem Assemble known quantities and assign variable names Discard unimportant data Establish relationships and express them as equations Determine the proper algorithm by arranging the equations in correct sequence.
1. 2. 3. 4. 5.
r Input or output
r processing
ow line
Read number1
Read number2 Print Error Message if number 2 =0 Yes sI 0=2rebmuN ? No Calculate the result Result= Number1/Number2 5 DNE
DNE
Q11 :Draw a flowchart to find the sum of first ... natural numbers. This
means that we want to find sum where sum is given by:
Sum= 1+2+3+..+99+100
tratS
airaV deraperP
1+N=N
N+ muS = muS
oN
DNE
Q12 :Draw a flowchart to find the sum of the first 25 odd natural
numbers.
Sum = 1 + 3+ 5 + here we add 25 odd natural numbers
tratS
Sum=0
Variable (N) as Counter and (T) for odd values Add odd values to Sum
N=N+1 T=T+2
No
52=N sI ?
Yes
muS tnirP
6
DNE
Sum=0
Sum = Sum +T
N=N+1 T=1/N
No
Is ?T<0.01 Yes
muS tnirP
DNE
Read A, B, C
Yes
IS B>C No
No
IS A>B
Yes IS A>C No
Yes
Print B
Print C
Print A
END
Solving the book questions page 34-35 Q16 :Donia drew a Flowchart to add two
numbers and printed the result as follows:
Start
:Answer
Start
Result= Number1+Number2
Read Number1
Read Number2 Read Number1 Result= Number1+Number2 Output the result 8 Result= Read Number2 ReadEND Number1 Number1+Number2
Read Number2
END
END
Q17 :Draw a flowchart to read the age of Hany and Hesham, then it prints the name of the elder.
Start
Read HanyAge
Is
HanyAge>HeshamAge
END
Q18 :Draw a flowchart that reads a temperature in Fahrenheit degrees and convert it into Celsius degrees, using the formula
=F-32) ( 9 C
Start Read F
(C=5/9(F-32
Print F END 9
Q19: Draw a flowchart that reads the radius of a sphere r, then it calculates volume V and surface area A using formulas:
4 22 r 3 , A=4 r 2 , = 7 3 If the read radius is negative, the flowchart should print a warning message then terminates.
Where V=
Start
r daeR Yes Is r < ?0 NO V= (4/3) * (22/7) * r^3 eb ton nac suidaR" tnirP orez neht ssel " A= 4 * (22/7) * r ^2 DNE A , V tnirP
DNE
10