Skip to content

Commit 58686e3

Browse files
authored
Update 2-7-2-6-reduction.md
Fixed spacing and readability issues with reduction statement forms
1 parent d3871ee commit 58686e3

1 file changed

Lines changed: 8 additions & 5 deletions

File tree

docs/parallel/openmp/2-7-2-6-reduction.md

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -47,10 +47,13 @@ variable-list
4747

4848
```
4949
50-
x = xopexprxbinop= exprx = expropx (except for subtraction)
51-
x++
52-
++xx--
53-
--x
50+
x = x op expr
51+
x binop= expr
52+
x = expr op x (except for subtraction)
53+
x++
54+
++x
55+
x--
56+
--x
5457
```
5558

5659
where:
@@ -126,4 +129,4 @@ for (i=0; i<n; i++) {
126129
/* ERROR - variable x cannot be specified in both
127130
a shared and a reduction clause */
128131
#pragma omp parallel for shared(x) reduction(+: x)
129-
```
132+
```

0 commit comments

Comments
 (0)