Scrython/examples/lookup_set_code.py

15 lines
284 B
Python
Raw Normal View History

2018-03-01 03:30:14 +00:00
import scrython
import time
query = input("Type the name of the set: ")
time.sleep(0.05)
sets = scrython.sets.Sets()
for i in range(sets.data_length()):
if sets.set_name(i) == query:
print("Set code:", sets.set_code(i).upper())
break
else:
continue