| LE | Index Level | LET |
| Syntax | LEN( string.expression ) |
| Category | BASIC |
| Type | Function |
| Description | returns the length of a string expression. |
| Options | |
| See Also | statements & functions string.expression functions |
| Example |
customer = "john"
name.length = len(customer) print name.length 4 string = "testt" string = string[1,len(string)-1] print string test This assignment statement uses the "len" function to delete the last character of "string". string = 'abcde' print len(string) This outputs a 5. a = 5 x = len(a * 10) print x 2 This code gets the length of the result of an arithemtic expression. The result of the arithmetic expression is converted to an ASCII string when the "len" function is invoked. The output is 2, since 5 times 10 is 50, and the length of 50 is 2 characters. |
| Warnings | |
| Compatibility | D3 7.0 AP R83 |
| LE | Index Level | LET |