diff options
author | Jitse Niesen <jitse@maths.leeds.ac.uk> | 2011-06-03 11:17:08 +0100 |
---|---|---|
committer | Jitse Niesen <jitse@maths.leeds.ac.uk> | 2011-06-03 11:17:08 +0100 |
commit | 7a61a564ef7d5403bcf3eef0c84252cc8bf73705 (patch) | |
tree | 2138d2bd9d1621f4a816f890a9148f4367950841 /doc/snippets | |
parent | 5bc4abc45e20b862cd1af678d11a19d02d3e2e19 (diff) |
Fix snippets for operator|| and && by adding pair of parens.
Diffstat (limited to 'doc/snippets')
-rw-r--r-- | doc/snippets/Cwise_boolean_and.cpp | 2 | ||||
-rw-r--r-- | doc/snippets/Cwise_boolean_or.cpp | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/doc/snippets/Cwise_boolean_and.cpp b/doc/snippets/Cwise_boolean_and.cpp index 081004be4..df6b60d92 100644 --- a/doc/snippets/Cwise_boolean_and.cpp +++ b/doc/snippets/Cwise_boolean_and.cpp @@ -1,2 +1,2 @@ Array3d v(-1,2,1), w(-3,2,3); -cout << (v<w) && (v>0) << endl; +cout << ((v<w) && (v<0)) << endl; diff --git a/doc/snippets/Cwise_boolean_or.cpp b/doc/snippets/Cwise_boolean_or.cpp index e336cf462..83eb0068e 100644 --- a/doc/snippets/Cwise_boolean_or.cpp +++ b/doc/snippets/Cwise_boolean_or.cpp @@ -1,2 +1,2 @@ Array3d v(-1,2,1), w(-3,2,3); -cout << (v<w) || (v<0) << endl; +cout << ((v<w) || (v<0)) << endl; |