I get back good results from the following, but how to I extract that data from the tuple? In other words, how do I clean up the data?
Here is the data from the data
A notion that I like, that might confuse to begin with, is the following:
Python2
policy_id = ((2309L,), (118L,), (94L,))
for i, in policy_id:
print i
Python3
policy_id = ((2309,), (118,), (94,))
for i, in policy_id:
print(i)
The ,
after the i
unpacks the element of a single-element tuple (does not work for tuples with more elements than one).