Practice
In-Range Function
EASYProcedures & Functions5 marks
Write function InRange(Value, Low, High) that returns TRUE if Value is between Low and High inclusive, otherwise FALSE.
The main program reads three integers and outputs the function result.
Input: Value, then Low, then High.
Output: TRUE or FALSE.
Example:
Input: 7
1
10
Output: TRUE
Sample Test Cases
Test 1: Inside the range
Inputs: 7, 1, 10
Expected: TRUE
Test 2: Below the range
Inputs: 0, 1, 10
Expected: FALSE