Author Topic: i am a noob i wish for help  (Read 8591 times)

0 Members and 1 Guest are viewing this topic.

Offline Happybobjr

  • James Oldiges
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2325
  • Rating: +128/-20
  • Howdy :)
    • View Profile
i am a noob i wish for help
« on: May 31, 2010, 07:27:12 pm »
ok i am extremely new at thiis
what is wrong with my prog.
all i know so far is that i think prompt is not supported
____________________________________________________
sry parents get on just to bug me and dont let me finish
_______________________________________________
also i am completely new at axe so things will look comppletely wrong
_________________________________________________
Code: [Select]
.AXEEE
0->A
1->B
Prompt {C}r
If {C}r less than or equal to 2
Stop
If Remainder({C}r,2)=(0)
A+1->A
While ({C}r//B)  greater than or equal to  (squareroot({C}r))
If Remainder({C}r,B)=(0)
A+1->A
B+2->B
If A greater than or equal to 2
Goto 1
End
Disp "PRIME"
Stop
Lbl 1
Disp "Composite"
Pause
Disp "BYE"
« Last Edit: May 31, 2010, 08:03:40 pm by happybobjr »
School: East Central High School
 
Axe: 1.0.0
TI-84 +SE  ||| OS: 2.53 MP (patched) ||| Version: "M"
TI-Nspire    |||  Lent out, and never returned
____________________________________________________________

_player1537

  • Guest
Re: i am a noob i wish for help
« Reply #1 on: May 31, 2010, 07:28:17 pm »
it certainly is not.  I made an input routine, I forget where it went.  and...where is your program...?  Also, there is a command list in the .zip file, with documentation that will tell you how to get started
« Last Edit: May 31, 2010, 07:28:54 pm by _player1537 »

Offline LordConiupiter

  • LV6 Super Member (Next: 500)
  • ******
  • Posts: 339
  • Rating: +3/-0
  • Just one of the thousands of Axe-fans...
    • View Profile
Re: i am a noob i wish for help
« Reply #2 on: June 01, 2010, 03:43:32 pm »
ok i am extremely new at thiis
what is wrong with my prog.
all i know so far is that i think prompt is not supported
____________________________________________________
sry parents get on just to bug me and dont let me finish
_______________________________________________
also i am completely new at axe so things will look comppletely wrong
_________________________________________________
Code: [Select]
.AXEEE
0->A
1->B
Prompt {C}r
If {C}r less than or equal to 2
Stop
If Remainder({C}r,2)=(0)
A+1->A
While ({C}r//B)  greater than or equal to  (squareroot({C}r))
If Remainder({C}r,B)=(0)
A+1->A
B+2->B
If A greater than or equal to 2
Goto 1
End
Disp "PRIME"
Stop
Lbl 1
Disp "Composite"
Pause
Disp "BYE"
The Disp command does only support pointers, not strings like u did
so
Code: [Select]
Disp "BYE"
should be:
Code: [Select]
"BYE"->Str1
Disp Str1
everytime that I was down, you would always come around, and get my feedback on the ground. (modified part from 'Seasons in the sun')

No matter how many errors are bothering you, always try to stay rel-Axe!

The HoMM project will be resumed as soon Axe 1.0.0 will be released!
Projects:
Code: [Select]
HoMM:   [==--------]    Project 'resumed': I'm suffering overwhelming new ideas being popped up in my dreams :P
tiDE:   [----------]    Explored and understood the main part of the code: just started writing a Tokenizer.



password of the week: uvanapererubupa (Any pronunciation is the right one ;) )   :D click me, and you'll be raided :D

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55941
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: i am a noob i wish for help
« Reply #3 on: June 01, 2010, 03:47:49 pm »
What is Remainder()? Also Axe doesn't support the Stop command.

Welcome here by the way :)
« Last Edit: June 01, 2010, 03:48:33 pm by DJ Omnimaga »

Offline Happybobjr

  • James Oldiges
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2325
  • Rating: +128/-20
  • Howdy :)
    • View Profile
Re: i am a noob i wish for help
« Reply #4 on: June 01, 2010, 06:49:20 pm »
thanks for the help
i really appreciate this great community where people a patient and help others learn.  none of the "go away noob"
i really appreciate it.

the remainder command is a newer command on the ti-84 that came out with the new os that came out early this year ( the one enabling math-print )
basically

Disp Remainder(5,2)          "  5 divided by 2 "  2 and 1 over 2    remainder 1" "stuff in 1st grade"

outcome would be 1
School: East Central High School
 
Axe: 1.0.0
TI-84 +SE  ||| OS: 2.53 MP (patched) ||| Version: "M"
TI-Nspire    |||  Lent out, and never returned
____________________________________________________________

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: i am a noob i wish for help
« Reply #5 on: June 01, 2010, 07:06:06 pm »
I'm new to Axe too, but I'm pretty sure this is the problem:

Axe doesn't just translate BASIC commands. It crates a totally separate language, so it only accepts the ones that it itself supports, and so most of the commands that you'd use in BASIC, like Remainder(, would not work in Axe.

And for those of you more experienced in Axe programming, I have a question too: Is it compatible with OS 2.53?
« Last Edit: June 01, 2010, 07:07:46 pm by Deep Thought »




Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55941
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: i am a noob i wish for help
« Reply #6 on: June 01, 2010, 07:20:05 pm »
thanks for the help
i really appreciate this great community where people a patient and help others learn.  none of the "go away noob"
i really appreciate it.

the remainder command is a newer command on the ti-84 that came out with the new os that came out early this year ( the one enabling math-print )
basically

Disp Remainder(5,2)          "  5 divided by 2 "  2 and 1 over 2    remainder 1" "stuff in 1st grade"

outcome would be 1
No problem,

Omnimaga promotes respect between members and welcome new members to encourage them to program and stuff  ^^

That said, I think what the issue is is what Deep Thought said. Only the commands listed in the "commands.html" file that comes with Axe parser will work.

And to awnser Deep Thought: yes it will work. It also works on TI-Nspire

Offline Ti-newb

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 180
  • Rating: +3/-0
    • View Profile
Re: i am a noob i wish for help
« Reply #7 on: June 01, 2010, 07:25:43 pm »
Hi Happybobjr, I was new here like .. 8 months ago and im still a newb =D so no problem if ur a starter, lots of people can help you make ur programs.

Welcome to Omnimaga!!! =D

Offline ztrumpet

  • The Rarely Active One
  • CoT Emeritus
  • LV13 Extreme Addict (Next: 9001)
  • *
  • Posts: 5712
  • Rating: +364/-4
  • If you see this, send me a PM. Just for fun.
    • View Profile
Re: i am a noob i wish for help
« Reply #8 on: June 01, 2010, 07:47:36 pm »
Welcome here!

Disp Remainder(5,2)          "  5 divided by 2 "  2 and 1 over 2    remainder 1" "stuff in 1st grade"
outcome would be 1
It sounds like modulus, which in Axe is represented with the ^.  For example, 5^2 = 1. ;D
I hope this helped! :D Good luck! :)

Offline Happybobjr

  • James Oldiges
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2325
  • Rating: +128/-20
  • Howdy :)
    • View Profile
Re: i am a noob i wish for help
« Reply #9 on: June 01, 2010, 11:02:43 pm »
I'm new to Axe too, but I'm pretty sure this is the problem:

Axe doesn't just translate BASIC commands. It crates a totally separate language, so it only accepts the ones that it itself supports, and so most of the commands that you'd use in BASIC, like Remainder(, would not work in Axe.

And for those of you more experienced in Axe programming, I have a question too: Is it compatible with OS 2.53?


i changed to = int(  "interger" for new method that works as well if not better"
............................................
new question
is there any way to have commands such as prompt or input to work
if i have either it will give me err when compiling err.bad symbol
any way i can go around it so i can have a user input a number.
i have gotten this to work (w/o inputing the number) so that is the final step
i will try to add the code tomarrow.  its already 11:00 pm right now.
School: East Central High School
 
Axe: 1.0.0
TI-84 +SE  ||| OS: 2.53 MP (patched) ||| Version: "M"
TI-Nspire    |||  Lent out, and never returned
____________________________________________________________

Offline Ti-newb

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 180
  • Rating: +3/-0
    • View Profile
Re: i am a noob i wish for help
« Reply #10 on: June 01, 2010, 11:14:32 pm »
Input.. i cant find it in the Commands List.. so it is not supported.. but what u could do.. (a little more advanced..) is use the Getkey command.. im assuming u dont know what it does other then.. it "gets a key".. so heres a little tutorial

In Basic, Getkey would usually be used.. like Getkey-> (any variable.. for me.. i tend to pick G) G.. and if u run that through a loop, and press.. say the button Clear, it will give u a value of 45. in BASIC, the Getkey Command has everything as like.. a graph, but that is irrelevant. in AXE, you'll have to look at this: http://tibasicdev.wdfiles.com/local--files/key-codes/xlib-keys.png  

If ur still confused or uhh.. idk =D ask more questions, but experiment with it..
heres an example..

Repeat G=15 (15 is when u press Clear.. and when u do press 15, it'll exit the loop)
Getkey->G
If G
Output(1,1
Disp G >Decimal   (that > is the black triangle.. "Math, 2")
End
End

This should tell u the Values of the Pressed Buttons.
« Last Edit: June 01, 2010, 11:14:49 pm by Ti-newb »

_player1537

  • Guest
Re: i am a noob i wish for help
« Reply #11 on: June 01, 2010, 11:17:29 pm »
typically for my code to check key value, I use
Code: [Select]
0-K
repeat K
getkey->K
end
disp K>dec
but yours works too.  Also I made an input routine a while ago, if you'd like I can search for it.

Edit:  here you go http://ourl.ca/4129/80803
« Last Edit: June 01, 2010, 11:21:38 pm by _player1537 »

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: i am a noob i wish for help
« Reply #12 on: June 01, 2010, 11:58:40 pm »
i will try to add the code tomarrow.  its already 11:00 pm right now.

For some reason, the time difference still surprises me (pleasantly). We're all having conversations with people thousands of miles away.

I LOVE THE INTERNET. :D

Anyway, so the only form of input in Axe is through getKey?

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55941
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: i am a noob i wish for help
« Reply #13 on: June 02, 2010, 12:03:10 am »
yeah. There are two getkey methods too. One is similar to BASIC syntax and one is direct keypresses. getkey alone will return the key pressed code. Getkey(keycode) returns 1 or 0 depending if the key is pressed or not. The later method allows diagonal keypresses and faster keypresses

Offline Happybobjr

  • James Oldiges
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2325
  • Rating: +128/-20
  • Howdy :)
    • View Profile
Re: i am a noob i wish for help
« Reply #14 on: June 02, 2010, 03:54:45 pm »
ok i looked at these when i was at school but unfortunatly i haven't found a way to bypass the restrictions on installing the ti drivers for the schools computers so i could not add this on but here it is
updated working code for prime and composite
graphics:1/5
working: 4/5  (number must be below 5)
code clean?: 2/5
effort: 3/5

Code: [Select]
.AX3
0=>H
0=>G
3=>B
Lbl 2
getKey=>G
If G=33:H*10H:End
If G=34:H*10=>H:H+1=>H:End
If G=26:H*10=>H:H+2=>H:End
If G=18:H*10=>H:H+3=>H:End
If G=35:H*10=>H:H+4=>H:End
If G=27:H*10=>H:H+5=>H:End
If G=19:H*10=>H:H+6=>H:End
If G=36:H*10=>H:H+7=>H:End
If G=28:H*10=>H:H+8=>H:End
If G=20:H*10=>H:H+9=>H:End
If H (not equal) 0:Output(5,1,H (black triangle) Dec):End
If G (not equal) 9:Goto 2:End
H=>C
If C^2=0:Goto 1:End
While (C/B)(greater than or equal to) squ(C)                 “squ = square root of”
If C^B=0
Goto 1:End
B+2=>B
End
"PRIME"=>Str1
Disp Str1
Goto (theta)
Lbl 1
"Composite"=>Str2
Disp Str2
Lbl (theta)
Pause 999
School: East Central High School
 
Axe: 1.0.0
TI-84 +SE  ||| OS: 2.53 MP (patched) ||| Version: "M"
TI-Nspire    |||  Lent out, and never returned
____________________________________________________________