Mailing list for all users of the OCaml language and system.
 help / color / mirror / Atom feed
From: Shawn Wagner <shawnw@speakeasy.org>
To: caml-list@inria.fr
Subject: Re: [Caml-list] Substring search on an array of strings
Date: Thu, 24 Jun 2004 08:51:21 -0700	[thread overview]
Message-ID: <20040624155121.GB595@speakeasy.org> (raw)
In-Reply-To: <Pine.A41.4.44.0406240832570.503890-100000@ibm1>

On Thu, Jun 24, 2004 at 09:52:37AM +0200, Diego Olivier Fernandez Pons wrote:
>     Bonjour,
> 
> Caml Str library does not seem to provide a function allowing to match
> efficently a string in a array of strings.
> 
> I was wondering if there were already known algorithms for this before
> I try the workarounds I had in mind :


Do you want to find out if one of the strings in the array equals some other
string, or if that other string appears as a substring in one of the array's
strings? Either way, annexlib has the needed functions:
http://raevnos.pennmush.org/code/annexlib/

-- 
Shawn Wagner
shawnw@speakeasy.org

-------------------
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners


  reply	other threads:[~2004-06-24 15:48 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-06-24  7:52 Diego Olivier Fernandez Pons
2004-06-24 15:51 ` Shawn Wagner [this message]
2004-06-25 16:21   ` Diego Olivier Fernandez Pons
     [not found] <20040625165512.GG595@speakeasy.org>
2004-06-25 17:05 ` Diego Olivier Fernandez Pons
2004-06-25 17:25   ` Shawn Wagner

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20040624155121.GB595@speakeasy.org \
    --to=shawnw@speakeasy.org \
    --cc=caml-list@inria.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox