xHarbour Reference Documentation > Function Reference |
Removes duplicate adjacent words (2-byte sequences) from a string.
WordOne( <cWordList>, <cString> ) --> cResult
The function searches for duplicate adjacent 2-byte sequences (words) in <cString> and removes them in the result string.
See also: | CharOne(), I2Bin() |
Category: | CT:String manipulation , Character functions |
Source: | ct\charone.c |
LIB: | xhb.lib |
DLL: | xhbdll.dll |
// The example displays results of WordOne() PROCEDURE Main LOCAL cString := "abab12cd1212cdefef" ? WordOne( "12" , cString ) // result: abab12cd12cdefef ? WordOne( "abef", cString ) // result: ab12cd1212cdef RETURN
http://www.xHarbour.com