I am wondering if there is a way to do something like this in python 2.7.12
def saveValues(file,*data,delim="|"):
buf=""
for d in data:
buf+=str(d) + delim
open(file,"w").write(buf[:-1])
It's possible in python3. The python2 workaround is usually this:
def saveValues(file, *data, **kwargs):
delim = kwargs.pop('delim', '|')
...