<< Home | About Forth | About TurboForth | Download | Language Reference | Resources | Tutorials | YouTube >>


FINDC$ Search:

In Transient String Words in String Library

Word Name: FINDC$
Type: Standard word
Data Stack Signature: char -- pos|-1 / ss: --
Return Stack Signature: --
Availability: V1.2
Description:

Searches the topmost string on the string stack for the ascii character char, returning its position, or -1 if not found. Note: the first character in the string is character #0.

Example:

$" redgreenblue" ascii b findc$ . \ displays 8

Comment:

An error occurs if the string stack is empty.

See Also: FIND$  REPLACE$ 

<< Home | About Forth | About TurboForth | Download | Language Reference | Resources | Tutorials | YouTube >>