-1^2 == -(1^2) -- John
On Oct 22, 2014, at 2:39 PM, [email protected] wrote: > Could someone please explain to me how julia handles ^ operator. I'm confused > by this: > > > > > > > > > > $ julia > _ > _ _ _(_)_ | A fresh approach to technical computing > (_) | (_) (_) | Documentation: http://docs.julialang.org > _ _ _| |_ __ _ | Type "help()" for help. > | | | | | | |/ _` | | > | | |_| | | | (_| | | Version 0.3.1 (2014-09-21 21:30 UTC) > > > _/ |\__'_|_|_|\__'_| | > |__/ | x86_64-apple-darwin13.4.0 > > > julia> -1 ^ 2 > -1 > > > > > julia> (-1) ^ 2 > 1 > > > > > julia> -1 * -1 > 1 > >
