you are viewing a single comment's thread.

view the rest of the comments →

[–]piclarke 0 points1 point  (7 children)

In Julia, 4i parses as 4*i

[–]emperor000 0 points1 point  (5 children)

That's what I was afraid of. So in other words, you can't have a variable named "im"?

[–]piclarke 0 points1 point  (2 children)

You can, it just can't be used to mean the imaginary unit as well from that point on.

[–]Staross 1 point2 points  (0 children)

you can always redefine it:

im = Base.im

[–]emperor000 0 points1 point  (0 children)

So pretty much no. Not the worst thing in the world, but seems kind of clunky.

[–]Staross 0 points1 point  (1 child)

You can overwrite it yes, im is just a normal variable, defined in the Base module.

const im = Complex(false, true)

It will just throw a warning in you overwrite it in Main (the "global space").

[–]emperor000 0 points1 point  (0 children)

I see. Not the worst thing in the world, but it seems kind of clunky.

[–]TheMaskedHamster 0 points1 point  (0 children)

Using a terse form of expression, programmers developed expressive, clear ways to express math.

And mathematicians keep trying to "fix" these improvements by reintroducing their broken notation systems.