Posted December 15, 20222 yr dear all, i have a basic lisp-question to FORMAT and i did not find a solution... INPUT (setf alist '((/player "12" 1.0 1.0 1.0) (/player "23" 1.0 1.0 1.0) (/player "12" 1.0 1.0 1.0) (/player "23" 1.0 1.0 1.0))) ;; with FORMAT to => /player "12" 1.0 1.0 1.0, /player "23" 1.0 1.0 1.0, /player "12" 1.0 1.0 1.0, /player "23" 1.0 1.0 1.0 by FORMAT => i will save it in a TXT-file on desktop (that works (with-open-file...)), but i have a format-problems with the commatas and the () thanx for such basic-lisp-help andré
December 18, 20222 yr (format t "~{~{~S~^ ~}~^, ~}" alist) /player "12" 1.0 1.0 1.0, /player "23" 1.0 1.0 1.0, /player "12" 1.0 1.0 1.0, /player "23" 1.0 1.0 1.0 nil :: use format nil if you want the result as a string.
Create an account or sign in to comment