LearnPy Hub
← Tuples & Sets problems
Easy

Common Elements

Read two lines of integers and print the values that appear in both, in increasing order. Print None if there are none.

Input

Two lines.

Output

One line.

Sample 1

Input
1 2 3 4
3 4 5
Output
3 4

Sample 2

Input
1 2
3 4
Output
None
solution.py
Output appears here
Common Elements · Python practice problem · LearnPy Hub