lisp - Python-String to function in 'eval' -


i'm trying build lisp interpreter in python using 'eval'.

def func(e1,*elements): print(e1)  eval((input())) 

its working integers.but there way can use input strings?

eg: when input:

f(a,b,3,5,2) 

the above code should print:

a 

i don't want input as: f('a','b',3,5,2)

thanks!

the way convey string value enclosing within quote. other way declaring string variable separately , send parameter instead. however, when print string query in interactive command window, won't printed quotes aroun


Comments

Popular posts from this blog

c# - Binding a comma separated list to a List<int> in asp.net web api -

Delphi 7 and decode UTF-8 base64 -

html - Is there any way to exclude a single element from the style? (Bootstrap) -