Skip to content
This repository was archived by the owner on Aug 31, 2021. It is now read-only.

Commit b885bb1

Browse files
authored
Merge pull request #4931 from asayd/patch-19
[[ Documentation ]] Changes to asterisk.lcdoc
2 parents 2262603 + 38ee48e commit b885bb1

1 file changed

Lines changed: 18 additions & 12 deletions

File tree

docs/dictionary/operator/asterisk.lcdoc

Lines changed: 18 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -5,19 +5,21 @@ Type: operator
55
Syntax: <number1> * <number2>
66

77
Summary:
8-
Multiplies two numbers.
8+
Multiplies two numbers or arrays containing numbers.
99

1010
Introduced: 1.0
1111

12-
OS: mac, windows, linux, ios, android
12+
OS: mac, windows, linux, ios, android, html5
1313

1414
Platforms: desktop, server, mobile
1515

1616
Example:
17+
local thisNumber
1718
get 3 * 5 -- evaluates to 15
1819
put thisNumber * it into field "Result"
1920

2021
Example:
22+
local commonFactor, tempVariable
2123
put (3 + commonFactor) * 4 into tempVariable
2224

2325
Example:
@@ -28,25 +30,29 @@ put tArray * 10 into tProductArray
2830

2931
Parameters:
3032
number1:
31-
33+
A number or an expression that evaluates to a number, or an array
34+
containing numbers.
3235

3336
number2:
34-
The operands number2 and number2 are numbers or expressions that
35-
evaluate to numbers, or arrays containing numbers.
37+
A number or an expression that evaluates to a number, or an array
38+
containing numbers.
3639

3740
Description:
3841
Use the <*> (times) <operator> to multiply two numbers.
3942

43+
> *Note:* When used in complex arithmetic statements,
44+
<operator|operators> like <*> follows standard rules of <precedence>.
45+
4046
To multiply the contents of a container by a number, use the <multiply>
4147
<command> instead.
4248

4349
If either <number1> or <number2> is an <array>, each of the <array>
44-
<element(glossary)|elements> must be a number. If an <array> is
45-
multiplied by a number, each <element(keyword)> is multiplied by the
50+
<element|elements> must be a number. If an <array> is
51+
multiplied by a number, each <element> is multiplied by the
4652
number. If an <array> is multiplied by an <array>, both <array|arrays>
47-
must have the same number of <element(glossary)|elements> and the same
48-
dimension, and each <element(keyword)> in one <array> is multiplied by
49-
the corresponding <element(keyword)> of the other <array>.
53+
must have the same number of <element|elements> and the same
54+
dimension, and each <element> in one <array> is multiplied by
55+
the corresponding <element> of the other <array>.
5056

5157
If an element of one array is empty, the <*> <operator> treats its
5258
contents as zero.
@@ -56,8 +62,8 @@ The option to multiply arrays was introduced in version 1.1. In previous
5662
versions, only single numbers could be used with the * operator.
5763

5864
References: multiply (command), operator (glossary), array (glossary),
59-
command (glossary), element (glossary), element (keyword), / (operator),
60-
() (operator)
65+
command (glossary), element (glossary), / (operator),
66+
() (operator), precedence (glossary)
6167

6268
Tags: math
6369

0 commit comments

Comments
 (0)