#179. 范围判断

    ID: 179 Type: Default 1000ms 256MiB Tried: 0 Accepted: 0 Difficulty: (None) Uploaded By: Tags>codingbatWarmup-1gesp1条件结构

范围判断

Range Check

Background

Dawei is teaching students about conditional statements. He has given a simple task, asking students to determine if two given numbers satisfy specific range conditions.

Problem Description

Given two integer values, return true if they are both in the range 30..4030..40 inclusive, or they are both in the range 40..5040..50 inclusive. Otherwise, return false.

Input Format

Input is given from standard input in the following format.

Two integers aa and bb, separated by a space.

Output Format

Output is printed to standard output in the following format.

Output true if the condition is met, otherwise output false.

Sample

30 31
true
30 41
false
40 50
true

Sample Explanation

Sample 1: 3030 and 3131 are both within the closed interval [30,40][30, 40], so true is returned. Sample 2: 3030 is within the closed interval [30,40][30, 40], but 4141 is within the closed interval [40,50][40, 50]. They are not in the same range, so false is returned. Sample 3: 4040 and 5050 are both within the closed interval [40,50][40, 50], so true is returned.

Constraints

For each test case, the time limit is 11 second, and the memory limit is 10241024 KiB. The input integers a,ba, b satisfy 0a,b1000 \le a, b \le 100.