lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

check undefined variable scheme


From: Gianmaria Lari
Subject: check undefined variable scheme
Date: Thu, 24 May 2018 09:56:26 +0200

The following function increase a counter by 1 and return it as string

#(define count 0) 
#(define (nextcount) (begin
                      (set! count (+ 1 count))
                      (number->string count)
                      )
   )

Is my code ok, or I should write it in a different way?
Is it possible to define "count" inside the function just in case it is undefined?

Thank you, g.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]