Author Topic: Axe closing parentheses  (Read 5255 times)

0 Members and 1 Guest are viewing this topic.

Offline boathouse2112

  • LV2 Member (Next: 40)
  • **
  • Posts: 23
  • Rating: +0/-0
    • View Profile
Axe closing parentheses
« on: August 01, 2012, 08:13:20 pm »
In TI BASIC you can shorten the code a bit by omitting ending parentheses and quotation marks. Is this also possible in Axe or will it get messed up?

Offline Scipi

  • Omni Kitten Meow~ =^ω^=
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1547
  • Rating: +192/-3
  • Meow :3
    • View Profile
    • ScipiSoftware
Re: Axe closing parentheses
« Reply #1 on: August 01, 2012, 08:14:54 pm »
I believe Axe requires you to close the parentheses. Since it's compiled and not interpreted, I think it ensures proper compilation and execution, else you'll get an error when you go to compile.
« Last Edit: August 01, 2012, 08:15:14 pm by HOMER-16 »

Imma Cat! =^_^= :3 (It's an emoticon now!)
Spoiler For Things I find interesting:
Spoiler For AI Programming:
Spoiler For Shameless advertising:

Spoiler For OldSig:





Spoiler For IMPORTANT NEWS!:
Late last night, Quebec was invaded by a group calling themselves, "Omnimaga". Not much is known about these mysterious people except that they all carried calculators of some kind and they all seemed to converge on one house in particular. Experts estimate that the combined power of their fabled calculators is greater than all the worlds super computers put together. The group seems to be holding out in the home of a certain DJ_O, who the Omnimagians claim to be their founder. Such power has put the world at a standstill with everyone waiting to see what the Omnimagians will do...

Wait... This just in, the Omnimagians have sent the UN a list of demands that must be met or else the world will be "submitted to the wrath of Netham45's Lobster Army". Such demands include >9001 crates of peanuts, sacrificial blue lobsters, and a wide assortment of cherry flavored items. With such computing power stored in the hands of such people, we can only hope these demands are met.

In the wake of these events, we can only ask, Why? Why do these people make these demands, what caused them to gather, and what are their future plans...

Offline Deep Toaster

  • So much to do, so much time, so little motivation
  • Administrator
  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 8217
  • Rating: +758/-15
    • View Profile
    • ClrHome
Re: Axe closing parentheses
« Reply #2 on: August 01, 2012, 10:09:25 pm »
Leaving off ending parentheses makes no difference in the size of the compiled program (the one that users will actually play), and it can create many bugs if the programmer isn't entirely sure of what he's doing.

For example, look at this code:
Quote from: Axe
{L1+5A
You probably think it's doing the same thing as this:
Quote from: Axe
{L1+5}A
But what it's really doing is this:
Quote from: Axe
{L1+5A}
That's the sort of thing you'll have to deal with if you get in the habit of leaving off parentheses in Axe. So just leave them on—one keystroke will save you a ton of trouble later ;)
« Last Edit: August 01, 2012, 10:09:54 pm by Deep Thought »




Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55943
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: Axe closing parentheses
« Reply #3 on: August 02, 2012, 01:48:13 am »
I remember certain Axe commands would tolerate non-closed parenthesises from time to time, but in some cases, your code would not work. Always close them, because as Deep said, unlike in TI-BASIC, the executable file size won't change if you don't close them.

Offline Sorunome

  • Fox Fox Fox Fox Fox Fox Fox!
  • Support Staff
  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 7920
  • Rating: +374/-13
  • Derpy Hooves
    • View Profile
    • My website! (You might lose the game)
Re: Axe closing parentheses
« Reply #4 on: August 02, 2012, 03:48:26 am »
Leaving off ending parentheses makes no difference in the size of the compiled program (the one that users will actually play), and it can create many bugs if the programmer isn't entirely sure of what he's doing.

For example, look at this code:
Quote from: Axe
{L1+5A
You probably think it's doing the same thing as this:
Quote from: Axe
{L1+5}A
But what it's really doing is this:
Quote from: Axe
{L1+5A}
That's the sort of thing you'll have to deal with if you get in the habit of leaving off parentheses in Axe. So just leave them on—one keystroke will save you a ton of trouble later ;)
Oh, that is maybe why I had some axe bugs.........

THE GAME
Also, check out my website
If OmnomIRC is screwed up, blame me!
Click here to give me an internet!