|
From: | Andrew Bernard |
Subject: | Re: Metronome mark stem length |
Date: | Mon, 17 Apr 2017 22:21:21 +1000 |
(define (sgn n)
(cond ((negative? n) -1)
((positive? n) 1)
(else 0)))
Am 16.04.2017 um 19:29 schrieb Thomas Morley:
#(define (sign x)
(if (= x 0)
0
(if (< x 0) -1 1)))
I can hardly imagine that default guile or any SRFI doesn’t already provide such a function – unfortunately I’m not well-versed enough to know… Anyone?
[Prev in Thread] | Current Thread | [Next in Thread] |