Re: Find what?

new topic     » goto parent     » topic index » view thread      » older message » newer message

On Mon, 6 Nov 2000 21:24:52 -0800, Thomas wrote:

>      Sorry, I meant to add another "bit" to it. I forgot to include that
>the users input was used in find(). So it would be something like:
>
>      include get.e
>
>      integer input
>      sequence word
>      word="beef"
>      atom findit
>       input=gets(0)
>      findit=find(input[1], word)    --input[1] otherwise the [#,10] extra
>                                     --10 for enter is added
>      ? findit
>
>
>      --->Thanks
>      ------> Thomas

So what is your question?

If I input "beer", I will get:
  find( 'b', "beef" ) = 1

If I input "elephant", I will get:
  find( 'e', "beef" ) = 2

If I input "pork", I will get:
  find( 'p', "beef" ) = 0

If I input "Beef", I will get:
  find( 'B', "beef" ) = 0

Is this what you want?  If not, provide examples like those above and the
result you would like to see.  Then we'll see about writing a function that
produces the desired results.  Are you looking for a function
like "find_all" or "match_all" that I posted previously?

-- Brian

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu