MathGroup Archive 2011

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Print bug with -script? (quotes display)


On Sep 6, 3:57 am, "Rolf.Mer... at gmail.com" <rolf.mer... at gmail.com>
wrote:
> On Sep 5, 12:09 am, Alan <alan.is... at gmail.com> wrote:
>
> > I am using Mathematica under Windows Vista.  To run Mathematica comma=
nds as a script, my understanding is that I should invoke
> >     math.exe -script <scriptname>
> > This is working, but if I print a string
> >     Print["Test"]
> > it prints surrounded by quotes (as written literally).
> > I find this highly undesirable: can the quotes be suppressed?
>
> > Also, this behavior seems to conflict with the documentation:http://ref=
erence.wolfram.com/mathematica/tutorial/PropertiesOfStrings...
>
> > Is it a bug?
>
> > Thanks,
> > Alan Isaac
>
> One possibility is to define your own Print function:
> myPrint[s_String]:=WriteString["stdout",s];
>
> Or, you could probably even do
> Unprotect[Print]; Print[s_String]:=WriteString["stdout",s];
>
> Another possibility would be to switch to Linux, since there this bug
> is not present.
>
> Rolf Mertig
> GluonVision GmbH
> Berlin

Confirmed, the bug is present in Windows and Mac OS X. Do the
developers run their code even once?



  • Prev by Date: Bernoulli Numbers
  • Next by Date: iteration question
  • Previous by thread: Re: Bernoulli Numbers
  • Next by thread: iteration question