Created
November 20, 2021 01:20
-
-
Save rnemeth90/fe8c00897b239effab2df371530e26a1 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import random | |
randomlist1 = [] | |
randomlist2 = [] | |
list = [] | |
for i in range(0,100): | |
a = random.randint(1,30) | |
b = random.randint(1,30) | |
randomlist1.append(a) | |
randomlist2.append(b) | |
for i in randomlist1: | |
for j in randomlist2: | |
if (i == j): | |
if (i not in list ): | |
list.append(i) | |
print(list) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment