I am looking to create a Excel/Google Sheet IFS() -like function in python where you can pass unlimited pairs of arguments:
def region_info(region_name1, region_list1, [region_name2, region_list2]...):
# do something with each region_name and region_list passed
norcal_list = ["john", "ken", "ben"]
socal_list = ["amy", "dan", "jose"]
region_info("Norcal", norcal_list, "Socal", socal_list)
I am not sure what is the most elegant way to approach this in Python. Can this be achieved by simply passing *arg
at the end or the arguments must be in **kwarg
?