• We need your support!

    We are currently struggling to cover the operational costs of Xtremepapers, as a result we might have to shut this website down. Please donate if we have helped you and help make a difference in other students' lives!
    Click here to Donate Now (View Announcement)

computer studies questions

Messages
91
Reaction score
0
Points
16
hey guys what did you put for the first algorithm...the one where we had to find errors???
 
Messages
97
Reaction score
2
Points
0
Are we actually allowed to discuss it here?? I mean its not 24 hours yet.. The Algorithm was the easiest so far..
 
Messages
91
Reaction score
0
Points
16
I didn't find the algorithm easy...I never understood how to write an algorithm...pffff!! :(
 
Messages
97
Reaction score
2
Points
0
Its going to be 24 hours.. So the errors were

Negative=1
Positive=1
and Print statement being inside the loop
Also the counter value was incremented inside.. though its a for Loop!
 
Messages
123
Reaction score
0
Points
0
Heshna said:
I didn't find the algorithm easy...I never understood how to write an algorithm...pffff!! :(


Start
Count = 0
wsum = 0
hsum = 0
while (count < 1000) do
Input w
Input h
If (h <= 0) or (h = "") or (w <= 0) or (w = "") Then
Output "Error! Try again"
Else
hsum = hsum + h
wsum = wsum + w
count = count + 1
End if
End while
Output ("Average Height:" and (hsum/1000))
Output ("Average Weight:" and (wsum/1000))
End

~~~~~~~~~~~~~~~~~

I'm sad how the algorithm was too easy :(
 
Messages
67
Reaction score
0
Points
0
:D :D
..one question was strange!!
euu..real time processing and real time transaction..i dont remember the question well!! :ugeek: :ugeek:
yea algo was ok
the spreadsheet was kind of confusing...
which graph was more appropriate!!>graph A or B??? :geek: :geek:
 
Messages
35
Reaction score
0
Points
16
come on tell us what the Algorithm question was ... its OK passed the 24hour limit
 
Messages
123
Reaction score
0
Points
0
examman said:
come on tell us what the Algorithm question was ... its OK passed the 24hour limit

a school was taking weight and height of 1000 students

write an algorithm toL

-input 1000 students weight and height
-calculate the average of height and weight
-output the averages
 
Messages
123
Reaction score
0
Points
0
Depletion said:
:D :D
..one question was strange!!
euu..real time processing and real time transaction..i dont remember the question well!! :ugeek: :ugeek:
yea algo was ok
the spreadsheet was kind of confusing...
which graph was more appropriate!!>graph A or B??? :geek: :geek:

graph B obviously as the bars with a higher range was closer to the label (100, 200, 300) making it easier to read!
 
Messages
35
Reaction score
0
Points
16
mimmi said:
examman said:
come on tell us what the Algorithm question was ... its OK passed the 24hour limit

a school was taking weight and height of 1000 students

write an algorithm toL

-input 1000 students weight and height
-calculate the average of height and weight
-output the averages

Thanks a lot ;)

total_1 = 0
total_2 = 0
For Counter = 1 to 1000
Input Height
Input Weight
If Input = Weight THEN total_1 = total_1+1
ELSEIF Input = Height THEN total_2 = total_2+1
Next Counter.
Avg_1 = total_1/1000
Avg_2 = total_2/1000
Output
Avg_1
Avg_2


Correct ? xD
 
Messages
97
Reaction score
2
Points
0
examman said:
mimmi said:
examman said:
come on tell us what the Algorithm question was ... its OK passed the 24hour limit

a school was taking weight and height of 1000 students

write an algorithm toL

-input 1000 students weight and height
-calculate the average of height and weight
-output the averages

Thanks a lot ;)

total_1 = 0
total_2 = 0
For Counter = 1 to 1000
Input Height
Input Weight
If Input = Weight THEN total_1 = total_1+1
ELSEIF Input = Height THEN total_2 = total_2+1
Next Counter.
Avg_1 = total_1/1000
Avg_2 = total_2/1000
Output
Avg_1
Avg_2


Correct ? xD


You forgot the error part.. We should include an error message so that the height and weight are within a certain limit
 
Messages
123
Reaction score
0
Points
0
mimmi said:
Heshna said:
I didn't find the algorithm easy...I never understood how to write an algorithm...pffff!! :(


Start
Count = 0
wsum = 0
hsum = 0
while (count < 1000) do
Input w
Input h
If (h <= 0) or (h = "") or (w <= 0) or (w = "") Then
Output "Error! Try again"
Else
hsum = hsum + h
wsum = wsum + w
count = count + 1
End if
End while
Output ("Average Height:" and (hsum/1000))
Output ("Average Weight:" and (wsum/1000))
End

~~~~~~~~~~~~~~~~~

I'm sad how the algorithm was too easy :(


Umm this should be correct
 
Messages
123
Reaction score
0
Points
0
examman said:
mimmi said:
examman said:
come on tell us what the Algorithm question was ... its OK passed the 24hour limit

a school was taking weight and height of 1000 students

write an algorithm toL

-input 1000 students weight and height
-calculate the average of height and weight
-output the averages

Thanks a lot ;)

total_1 = 0
total_2 = 0
For Counter = 1 to 1000
Input Height
Input Weight
If Input = Weight THEN total_1 = total_1+1
ELSEIF Input = Height THEN total_2 = total_2+1
Next Counter.
Avg_1 = total_1/1000
Avg_2 = total_2/1000
Output
Avg_1
Avg_2


Correct ? xD


Actually That's not correct =S it's asking for height and weight of all students! If input = weight then... Thingy is wrong as far as what I learned
 
Messages
35
Reaction score
0
Points
16
according to what i have studied and the question posed by mimmi this is correct :)
 
Messages
22
Reaction score
0
Points
0
examman said:
total_1 = 0
total_2 = 0
For Counter = 1 to 1000
Input Height
Input Weight
If Input = Weight THEN total_1 = total_1+1
ELSEIF Input = Height THEN total_2 = total_2+1
Next Counter.
Avg_1 = total_1/1000
Avg_2 = total_2/1000
Output
Avg_1
Avg_2
Correct ? xD
according to the algorithm, if there is a weight, it would skip the 7th line and will not calculate the height. so if you use just an "IF" instead of "ELSE IF" it should work. you should also include how to catch any errors
 
Messages
27
Reaction score
1
Points
0
total Weight=0
total Height=0
For count=1to 1000 do
Repeat Input weight and height
Until weight > 0 and height > o
total weight = total weight + weight
total height = total height + height
Next count
average weight = total weight/1000
average height = total height/1000
Print average weight
Print average height
 
Messages
91
Reaction score
0
Points
16
what was the answer for the question on real time processing and real time transaction???
 
Messages
1
Reaction score
0
Points
11
hey.. m gonaa give comp as an additional subject in d next year's oct-nov session,, n ill start stuying it after d may-june session.. so,, is there any way to get easily A* by studyin 3 months only..??
 
Top