Ti-83 Programming Tutorials |
|||||
| |||||
Chapter 6 - Beginner ProjectsHow does this section works?Programs of the type math, game, or miscellaneous will be shown here with an explanation of the code. It is recommended that you try the exercises. We will also (try to) provide code for the user exercises so you can compare our code with your own. Math Geometry problem solver program Program name: GEOSOLVE Lbl 1 ClrHome Menu("AREA SOLVER","RECTANGLE",2,"CIRCLE",3,"ABOUT",A,"QUIT",X) Lbl A Disp "THIS PROGRAM","SOLVES AREAS OF","VARIOUS SHAPES." Pause "-Made by Me" Goto 1 Lbl X Stop Lbl 2 Disp "-RECTANGLE-" Input "WIDTH:",A Input "HEIGHT:",B Disp "AREA IS:",A*B Pause Goto 1 Lbl 3 Disp "-CIRCLE-" Input "RADIUS:",A Disp "AREA IS:",pi*A^2 Pause Goto 1Notes: Use the pi symbol ([2nd] pi -- located on the caret button); when multiplying variables with other variables or numbers, you may omit the multiplication symbol (*); you can substitute the caret and 2 in A^2 with the actual squaring function. User: Implement an option to "show your work"; implement code to solve for the area of a triangle, or other shapes if you prefer. Game Number guessing program Program name: RANDFUN ClrHome RandInt(1,50)->A Disp "GUESS A NUMBER","FROM 1 to 50." Repeat A=B Input "GUESS:",B "HIGH" IF B<A "LOW" IF A!=B Disp "TOO "+Ans End Pause "YOU GOT IT!"Notes: != is the same as the 'Not Equals' sign. (located under [2nd] TEST) User: Make a game that rolls a pair of dice.
Miscellaneous Bouncing text: a program that makes a string bounce around the screen. Program name: FUNTEXT ClrHome "HELLO."->Str0 " "->Str1 Repeat Ans For(X,1,8,1) Output(X,1,Str0) For(Z,0,50,1) End Output(X,1,Str1) End For(X,7,2,-1) Output(X,1,Str0) For(Z,0,50,1) End Output(X,1,Str1) End getKey EndUser: Implement code to let the user enter their own message.
|
|||||
|