Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

[REBOL] Re: Case comparison?

From: joel:neely:fedex at: 15-Oct-2001 6:21

Hi, Hallvard, Hallvard Ystad wrote:
> Ah, that's of course (computer) logical. I was thinking human > logical: of course characters are a sort of strings...
I still periodically have to figure out which kind of logic to use... ;-) In a related vein:
>> uppercase "foo"
== "FOO"
>> uppercase %foo
== %FOO
>> uppercase http://foo.com/
== HTTP://FOO.COM/
>> uppercase [foo--foo--com]
== [FOO--FOO--COM]
>> uppercase #"a"
** Script Error: uppercase expected string argument of type: any-string. ** Where: uppercase #"a" -jn- -- ; sub REBOL {}; sub head ($) {@_[0]} REBOL [] # despam: func [e] [replace replace/all e ":" "." "#" "@"] ; sub despam {my ($e) = @_; $e =~ tr/:#/.@/; return "\n$e"} print head reverse despam "moc:xedef#yleen:leoj" ;