Difference between revisions of "Manuals/calci/LEN"
Jump to navigation
Jump to search
| Line 11: | Line 11: | ||
e.g. LEN("String") displays '''6''' as a result. | e.g. LEN("String") displays '''6''' as a result. | ||
| − | *LEN counts 1 byte per characters. LEN works with the languages that use 'Single Byte Character Set' (SBCS). | + | *LEN() counts 1 byte per characters. LEN() works with the languages that use 'Single Byte Character Set' (SBCS). |
*<math>txt</math> can be any string containing characters, numbers, symbols, blank space etc. | *<math>txt</math> can be any string containing characters, numbers, symbols, blank space etc. | ||
*If argument <math>txt</math> is directly entered in the command, it should be enclosed in double quotes (e.g. "Name"). | *If argument <math>txt</math> is directly entered in the command, it should be enclosed in double quotes (e.g. "Name"). | ||
| Line 55: | Line 55: | ||
*[http://en.wikipedia.org/wiki/String_(computer_science) String] | *[http://en.wikipedia.org/wiki/String_(computer_science) String] | ||
| + | *[http://en.wikipedia.org/wiki/SBCS Single-byte Character Set] | ||
Revision as of 09:43, 13 January 2014
LEN(txt)
- where, Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle txt} is a text string whose length is to be determined.
LEN() counts the number of characters in a text string.
Description
LEN(txt)
e.g. LEN("String") displays 6 as a result.
- LEN() counts 1 byte per characters. LEN() works with the languages that use 'Single Byte Character Set' (SBCS).
- Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle txt} can be any string containing characters, numbers, symbols, blank space etc.
- If argument Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle txt} is directly entered in the command, it should be enclosed in double quotes (e.g. "Name").
Examples
| Wel-Come | ||
| Apple Orange | ||
| 123*123 | ||
=LEN(A1) : Calculates the number of characters in a string referenced to cell A1. Displays 8 as the output. Character '-' is also counted.
=LEN(A2) : Calculates the number of characters in a string referenced to cell A2. Displays 12 as the output. Space Character is also counted.
=LEN(A3) : Calculates the number of characters in a string referenced to cell A3. Displays 7 as the output.
=LEN("<!#!>") :Displays 5 as the output.
=LEN(A1&A2) : Adds the character length of two strings referenced to cells A1 and A2. Displays 20 as the output.
=LEN(A3&"123") : Adds the character length of two strings referenced to cell A1 and "123". Displays 10 as the output.