|
From: Petr M. <mi...@ph...> - 2005-09-27 14:50:18
|
> One factor you might want to consider in this regard > is the increasing use of gnuplot driven by scripts of > dynamically-typed languages--Python, Perl, Tcl, Ruby, > PHP... In such cases unexpected results can arise as a > result of integer division being the default. Perhaps > adopting a Python-like approach (// for integer > division) initially driven by a switch (set division > true|integer) and eventually defaulting to true might > help. Python works like gnuplot: Python 2.3.4 (#1, Feb 7 2005, 15:50:45) [GCC 3.3.4 (pre 3.3.5 20040809)] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> print 5/2 2 >>> print 5//2 2 --- PM |