Puzzle 2017-03-28 AB

DECLARE @A TABLE
(
Number int
)

–data
INSERT INTO @A VALUES (1);
INSERT INTO @A VALUES (2);
INSERT INTO @A VALUES (3);
INSERT INTO @A VALUES (4);
INSERT INTO @A VALUES (5);
INSERT INTO @A VALUES (6);
INSERT INTO @A VALUES (7);
INSERT INTO @A VALUES (8);
INSERT INTO @A VALUES (9);
INSERT INTO @A VALUES (10);
INSERT INTO @A VALUES (11);
INSERT INTO @A VALUES (12);
INSERT INTO @A VALUES (13);
INSERT INTO @A VALUES (14);
INSERT INTO @A VALUES (15);
INSERT INTO @A VALUES (16);
INSERT INTO @A VALUES (17);
INSERT INTO @A VALUES (18);
INSERT INTO @A VALUES (19);
INSERT INTO @A VALUES (20);

DECLARE @B TABLE
(
Number int
)

–data
INSERT INTO @B VALUES (11);
INSERT INTO @B VALUES (12);
INSERT INTO @B VALUES (13);
INSERT INTO @B VALUES (14);
INSERT INTO @B VALUES (15);
INSERT INTO @B VALUES (16);
INSERT INTO @B VALUES (17);
INSERT INTO @B VALUES (18);
INSERT INTO @B VALUES (19);
INSERT INTO @B VALUES (20);
INSERT INTO @B VALUES (21);
INSERT INTO @B VALUES (22);
INSERT INTO @B VALUES (23);
INSERT INTO @B VALUES (24);
INSERT INTO @B VALUES (25);
INSERT INTO @B VALUES (26);
INSERT INTO @B VALUES (27);
INSERT INTO @B VALUES (28);
INSERT INTO @B VALUES (29);
INSERT INTO @B VALUES (30);

SELECT Number FROM @A
SELECT Number FROM @B

>