I have 2 .py files (data.py, access.py)
In access.py, I have a few strings:
Japan = ['brown', 'cow', 'around']
Korea = ['black', 'chicken', '344']
China = ['grey', '3411', 'leaf']
Indonesia = ['red', 'green', '']
In data.py, I have a module:
def whichcolour(country)
print("access + country[1]") # Doesn't work
My Results
What I am trying to achieve is, to run whichcolour
through data.py
and it will return/ print out whatever is in that list.
I know print(access.Japan[1])
works.. It returns cow
.
How should the print
statement be written such that it gives me the same result?