[R] Quiz {was "Quit asking me .."}

Martin Maechler maechler at stat.math.ethz.ch
Wed Sep 17 11:40:20 CEST 2003


>>>>> "Rob" == Robert Keefe <keef9490 at uidaho.edu>
>>>>>     on Wed, 17 Sep 2003 01:39:02 -0700 (PDT) writes:

    Rob> Henrik,

    Rob> Gotcha, with 25:

    Rob> Q=noquote(quote(q("no")))

which is beaten with 16:

         Q=delay(q("no"))

*BUT* that's really not a nice one (and if I had thought
about it in advance I hadn't asked about a minimal length solution). 

The purpose of the quiz was to demonstrate autoprinting and
print methods for S3 classes, and I'd judge Henrik clearly won
the first price (for now) with the 28-letter 
       Q="no";class(Q)=Q;print.no=q
which combines shortness and beauty.

I think this issue with of an [empty name]-class is something to
be considered further -- probably rather on R-devel.

Martin Maechler




More information about the R-help mailing list