Re: What is the precedence wrt Mathematica infix operators
- To: mathgroup at smc.vnet.net
- Subject: [mg82865] Re: [mg82800] What is the precedence wrt Mathematica infix operators
- From: John Fultz <jfultz at wolfram.com>
- Date: Thu, 1 Nov 2007 05:23:58 -0500 (EST)
- Reply-to: jfultz at wolfram.com
On Wed, 31 Oct 2007 06:13:44 -0500 (EST), congruentialuminaire at yahoo.com wrote: > Hello Mathematica UG: > > I cannot find operator precedence documented anywhere. With the > operators from Fortran (in the old days) this was always clear, i.e > '/' before '-'. > > I have been reading some code in the Trott Guidebooks which has > constructions like 'Head @@ face[[i]] / order'. I can guess that Part > has precedence in this expression, but what about Apply vs. Times? > > Looking at the OutputForm shows that Apply has precendence. But,... > > - Is this documented somewhere? > - Do all Mathematica operators take precedence over arithmetic operators? > > TIA. > > Regards.. If you search for Input Syntax in the help viewer, the first hit includes a table with all of the operators (infix, prefix, and postfix) listed in order of decreasing precedence (in the "Operator Input Forms" section). I agree that this should be easier to find. Sincerely, John Fultz jfultz at wolfram.com User Interface Group Wolfram Research, Inc.