CAPITALIZE(5)

Table of Contents

Name

capitalize capitalizes the first letter of a word

lower
translates letters to lowercase
upper
translates letters to uppercase

Synopsis

STRING capitalize(string)
STRING string;
STRING lower(string)
STRING string;
STRING upper(string)
STRING string;

Description

These components of the run-time library provide three useful string handling functions.

capitalize translates all letters in string to lower case, with the exception of the first letter, which is translated to upper case. lower translates all letters in string to lower case, and upper translates all letters in string to upper case. For all three functions the string is not copied; the change is made directly in the string argument. To first obtain a copy of the string, use the strsave function (see STRSAVE(5) ). The argument value is returned by all three functions.

Example

If the value of string variable s were «oHio» then: capitalize(s) returns «Ohio"

lower(s)
returns «ohio"
upper(s)
returns «OHIO"

See Also

STRSAVE(5)
ITOA(5)


© 1990 Lucent Technologies, Inc
© 1998 Harmony Software, Inc