Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Need some quick help (Anyone can help)

2 views
Skip to first unread message

skibud2

unread,
Oct 8, 2007, 4:57:42 PM10/8/07
to
I want to get the results for the following for each version of common
lisp

(sort '("zyzzyva" "zyzzyvas") #'string<)


For Clisp:
>> ("zyzzyva" "zyzzyvas")

For SBCL:
>> ??

For CMUCL:
>> ??

For Allegro:
>> ??

Thanks guys!

Mike

Dimiter "malkia" Stanev

unread,
Oct 8, 2007, 5:12:44 PM10/8/07
to
ACL81 (Win32):
CG-USER(1): (sort '("zyzzyva" "zyzzyvas") #'string<)
("zyzzyva" "zyzzyvas")

GNU CLISP 2.41 (2006-10-13) (Win32):
[1]> (sort '("zyzzyva" "zyzzyvas") #'string<)
("zyzzyva" "zyzzyvas")

Lispworks 5.0.2 (Win32):
CL-USER 1 > (sort '("zyzzyva" "zyzzyvas") #'string<)
("zyzzyva" "zyzzyvas")

Bob Felts

unread,
Oct 8, 2007, 8:12:40 PM10/8/07
to
skibud2 <mike.h...@gmail.com> wrote:

> I want to get the results for the following for each version of common
> lisp
>
> (sort '("zyzzyva" "zyzzyvas") #'string<)
>

I see you wrote this before Ranier mentioned that you shouldn't sort a
constant. The expression should be:

(sort (list "zyzzyva" "zyzzyvas") #'string<)

Timofei Shatrov

unread,
Oct 9, 2007, 4:42:13 AM10/9/07
to
On Mon, 08 Oct 2007 20:57:42 -0000, skibud2 <mike.h...@gmail.com> tried to
confuse everyone with this message:

>I want to get the results for the following for each version of common
>lisp
>
>(sort '("zyzzyva" "zyzzyvas") #'string<)
>
>
>For Clisp:
>>> ("zyzzyva" "zyzzyvas")
>

Don't worry, every other Common Lisp will return the same thing.

--
|Don't believe this - you're not worthless ,gr---------.ru
|It's us against millions and we can't take them all... | ue il |
|But we can take them on! | @ma |
| (A Wilhelm Scream - The Rip) |______________|

Thomas A. Russ

unread,
Oct 9, 2007, 9:36:35 PM10/9/07
to
skibud2 <mike.h...@gmail.com> writes:

> I want to get the results for the following for each version of common
> lisp
>
> (sort '("zyzzyva" "zyzzyvas") #'string<)

Why?
Are you trying to test conformance with the standard?

The correct behavior (modulo not modifying a constant) is mandated by
the ANSI standard.

--
Thomas A. Russ, USC/Information Sciences Institute

0 new messages