Code

Updated to upstream version 1.4.8.
[pkg-rrdtool.git] / doc / rpntutorial.html
index 74d8754758e5d3e75038ba02525a22973e4ae005..cc301912ed9092734562b2177feed5f06ddaedc4 100644 (file)
@@ -115,9 +115,9 @@ with multiple logic operators:</p>
 multiplication operator:</p>
 <pre>
  1) 128,8,*,7000,GT,7000,128,8,*,IF  eval 128,8,*       result is 1024
- 2) 1024,7000,GT,7000,128,8,*,IF     eval 1024,7000,GT  result is 0
- 3) 0,128,8,*,IF                     eval 128,8,*       result is 1024
- 4) 0,7000,1024,IF                                      result is 1024</pre>
+ 2) 1024   ,7000,GT,7000,128,8,*,IF  eval 1024,7000,GT  result is 0
+ 3) 0,              7000,128,8,*,IF  eval 128,8,*       result is 1024
+ 4) 0,              7000,1024,   IF                     result is 1024</pre>
 <p>Now let's go back to the first example of multiple logic operators,
 but replace the value 20 with the variable &quot;input&quot;:</p>
 <pre>
@@ -127,7 +127,7 @@ with &quot;A&quot;:</p>
 <pre>
  2) A,10,input,IF            eval is A,10,input,IF</pre>
 <p>read &quot;if A then 10 else input&quot;.  Now replace A with it's verbose
-description again and--voila!--you have a easily readable description
+description again and--voila!--you have an easily readable description
 of the expression:</p>
 <pre>
  if input &gt; 10 then 10 else input</pre>
@@ -173,7 +173,7 @@ uses the LE and DIV operators.</p>
 <p>Answer 2:</p>
 <pre>
     if (input &lt;= 56000/8 ) { input*8 } else { 56000 }
-    input,56000,8,DIV,LT,input,8,*,56000,IF</pre>
+    input,56000,8,DIV,LE,input,8,*,56000,IF</pre>
 <p>Exercise 3:</p>
 <p>Briefly explain why traditional mathematic notation requires the
 use of parentheses.  Explain why RPN notation does not require