Just now, Carl Eastlund wrote: > You can also write: > > (for*/list ([(k v) (in-hash ht)] > [res (in-value (f k v))] > #:when res) > res)
[It does seem a little too verbose with the 3 mentions of `res', but that's the same kind of verbosity as repeating `x' in: (for/list ([x (in-range 100 110)]) x) If there was some rule like "with no body, the last bound loop variable(s) is used", then this becomes (for/list ([x (in-range 100 110)])) and the above: (for*/list ([(k v) (in-hash ht)] [res (in-value (f k v))] #:when res)) ] -- ((lambda (x) (x x)) (lambda (x) (x x))) Eli Barzilay: http://barzilay.org/ Maze is Life! _________________________________________________ For list-related administrative tasks: http://lists.racket-lang.org/listinfo/dev