Help with a question (1 Viewer)

sasquatch

Member
Joined
Aug 15, 2005
Messages
384
Gender
Male
HSC
2006
This question is from Samuel Davis' Software Design and Development preliminary course. Question is 14 from Chapter 6, Set A (Page 228).

The following algorithm has been written to control the temperature of an oven. Use this following algorithm to answer questions 13, 14 and 15.

BEGIN ControlTemp
Get Temp​
REPEAT​
Get CurrentTemp from Sensor​
IF CurrentTemp >= Temp THEN​
Turnoff heat element​
ELSE​
If Current Temp < Temp - 5 THEN​
Turnon heat element​
ENDIF​
ENDIF​
Wait 1 minute​
UNTIL Power is turned off​
END ControlTemp

14. Design a set of test data to perform path and decision coverage testing.

Can somebody please help me with this? Thanks.
 
Last edited:

aaaman

Banned
Joined
Jan 5, 2005
Messages
851
Location
The Shire
Gender
Male
HSC
2005
sasquatch said:
This question is from Samuel Davis' Software Design and Development preliminary course. Question is 14 from Chapter 6, Set A (Page 228).

The following algorithm has been written to control the temperature of an oven. Use this following algorithm to answer questions 13, 14 and 15.

BEGIN ControlTemp
Get Temp​
REPEAT​
Get CurrentTemp from Sensor​
IF CurrentTemp >= Temp THEN​
Turnoff heat element​
ELSE​
If Current Temp < Temp - 5 THEN​
Turnon heat element​
ENDIF​
ENDIF​
Wait 1 minute​
UNTIL Power is turned off​
END ControlTemp

14. Design a set of test data to perform path and decision coverage testing.

Can somebody please help me with this? Thanks.

pretty much its getting the tempurate for you and if equals the temp u need it will turn off the heater otherwise if the temp is below what it needs its gonna keep the oven warm
 
Joined
Nov 4, 2004
Messages
3,550
Location
Sydney
Gender
Male
HSC
2005
Try a series of 100, 50, 30, 10 then try negatives, it doesnt seem that difficult compared to year 12 algorithms :(
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Top