From: Erik Naggum
Subject: Re: character Comparison
Date: 
Message-ID: <3160029562363276@naggum.no>
* "Chris H" <···············@NOJUNKhome.com>
| how do I check if  character 'a' is in word 'banada'
| 
| is any thing like substring() function ?

  yes.  FIND, POSITION, SEARCH, CHAR, SUBSEQ, etc.

  note that most operations on characters and strings in Common Lisp are
  simply special cases of operations on elements and sequences.  many
  C-based programmers are frustrated because they think that Common Lisp
  has few string-handling functions.  Common Lisp has few string-only
  functions, so remember to look for sequence and array functions, too.

#:Erik
From: Erann Gat
Subject: Re: character Comparison
Date: 
Message-ID: <gat-2202000918570001@milo.jpl.nasa.gov>
In article <················@naggum.no>, Erik Naggum <····@naggum.no> wrote:

> * "Chris H" <···············@NOJUNKhome.com>
> | how do I check if  character 'a' is in word 'banada'
> | 
> | is any thing like substring() function ?
> 
>   yes.  FIND, POSITION, SEARCH, CHAR, SUBSEQ, etc.
> 
>   note that most operations on characters and strings in Common Lisp are
>   simply special cases of operations on elements and sequences.  many
>   C-based programmers are frustrated because they think that Common Lisp
>   has few string-handling functions.  Common Lisp has few string-only
>   functions, so remember to look for sequence and array functions, too.

As long as we're on the subject, what is the best way to iterate over
a string/sequence?  (map nil ... s)?  (dotimes (i (length s)) ...
(char s i) ...)?

E.