[racket] style: nested cond (fine!)

From: Stephen Bloch (bloch at adelphi.edu)
Date: Tue Feb 21 11:32:15 EST 2012

On Feb 21, 2012, at 11:15 AM, Matthias Felleisen wrote:

> If they were to write this code in Java ('CS2'), they wouldn't have conds for the outer part -- they'd use dispatch.

Only if they were using polymorphic data structures.  But most of the Real World uses null-terminated data structures instead, despite that approach's practical disadvantages, so students need to learn how to work with them too -- and CS2 seems like an appropriate place to do that.  So yes, they WOULD have a conditional for the outer part.

Stephen Bloch
sbloch at adelphi.edu

Posted on the users mailing list.