
-----------------------------------
.hack
Fri Feb 06, 2004 4:27 pm

Turing Swiss Army Knife
-----------------------------------
Well, I've started programming a "swiss army knife" like tool in Turing. What it basically is, is a conversion program. Right now I am working on, measurements, weighy, temperature and money conversions. THis is just a simple utility for doing quick math, if you want to know how many CM are in a foot, jus followt he menus to convert feet into Centimetres etc. And the same goes for weight, temp etc etc.

I plan on adding more conversions, and I am even trying to create text menu :P.

Oh well, this is just what I am working on, if anyone is interested in it, I can post it up, I know its not too high tech, but for my skill level it is(I just finished a program that allows the input of a cars travelliug start time, end time, distance and then outputs the total time and average speed :D

Oh well, just so you guys know of the things to come :)

-----------------------------------
Cervantes
Fri Feb 06, 2004 4:31 pm


-----------------------------------
A good program to make.  Post the code; if it isn't very efficient we can teach you how to make it more efficient.

Also on a program like this I would suggest going a bit overboard and learning how to make menus.  Either learn GUI, or make your own using Mouse.Where or Input.KeyDown.

-----------------------------------
.hack
Fri Feb 06, 2004 4:35 pm


-----------------------------------
thanks for the advice, I was planning something like this

if 1 = 1 then
put "you have selected blah blah blah"
get rCM
rAns := rCM *2.14
put "rCM is equal to ", rAns

or something liek that  and use if statements for most of the options with Else statements. I would have to make the menus effiecien enough so Id idn't have like 800 if statements.

remember its like my 5th learning turing at school, so I don't know too much =/

-----------------------------------
Cervantes
Fri Feb 06, 2004 5:03 pm


-----------------------------------
text based?  if your up for it, I would suggest trying to make buttons and such

ie. have a main menu where you click on the button you want (say, "INCHES  CM") and it takes you to a new screen where you enter the value for INCHES in a textbox and click convert and it appears in the CM text box.

That would be fairly hard.  if you try it just do the first one, then post it :)

-----------------------------------
Dan
Fri Feb 06, 2004 6:30 pm


-----------------------------------
migth as well post it all since u all ready stared this topic, lol.

P.S. i saw ur name is .hack, that have anything to do with .hack// anime?

-----------------------------------
.hack
Fri Feb 06, 2004 10:04 pm


-----------------------------------
%||Name: Stuart Montreuil                                                   ||
%||Class: ICS3M                                                             ||
%||Program File: StuartM51                                                  ||
%||Description: Large Conversion Program for Length,Weight,Temp             ||



%Variables for Length Conversion
var rInch,rCM,rMM,rM,rMile,rKM,rFt : real

%Variables for Solid Weight Conversion
var rPnd,rGrm,rKgrm,rOnc,rMgrm : real

%Variables For Liquid Weight Conversion
var rL,rMl,rOun,rGal : real

%Code
put "Choose a Conversion Topic:"
put ""
put "1.","Length and Width Measurements"
put "2.","Solid Weight Measurements"
put "3.","Liquid Weight Measurements"
put "4.","Temperature"

if 1 = 1 then
put ""
put "Length And Width Measurments"
put ""
put "Choose Your Operation"
put ""
put "1.mm to centimetre."
put "2.mm to feet."
put "3.mm to metre."
put "4.mm to kilometre."
put "5.mm to miles."
put "6.cm to mm."
put "7.cm to feet."
put "8.cm to metre."
put "9.cm to kilometre."
put "10.cm to mile."


put "Please enter the length in Inches"
get rInch
rCM := rInch * 2.54
put " "
put rInch, " inches", " is ", rCM, " centimetres"
put " "

put "Measurement Utility Writen by .hack of Binary 3"
end if


is all I hav really done so far, and I know the code there is not complete. As you can see its going to be a biatch to code all of the if statements when everything is sort of jumbled together, but I believe I can pull through.

I watch very little anime, and have never played the game series. But .hack sounded cool and its geeky so I chose it :)

P.S the codea t the bottom that is broken away from the large list of puts, is jsut the original code I to do in class for our assignment, so pretty much disregard that. its more like a model for me to view to keep self in check.

-----------------------------------
Cervantes
Sat Feb 07, 2004 9:49 am


-----------------------------------
if you are having trouble keeping it organized, use procedures.  they are very very easy to use / learn and will help enourmously for keeping you organized.

Looks not too bad, if you do make it text based then I would suggest making it look nice with background colours and text colours and a fancy title etc.  Everything is better if it looks better!

you don't need to have that 'if 1=1 then" in there.. 1always=1, so there's no way that it could not enter that if statement. 

what you would need eventually is a similar if statement around that section where you choose what measurments you want to convert.  except you'll have a variable for your first choice (measurment, temperature, weight etc.) and then "if (thatvar)=1 then"

Good job, keep working on it :)

-----------------------------------
.hack
Sat Feb 07, 2004 2:34 pm


-----------------------------------
I'm willing to learn if you willing to teach :)

-----------------------------------
Maverick
Sat Feb 07, 2004 2:42 pm


-----------------------------------
Hacker Dan created .hack.

Ya pretty good prog, but if you know how to create buttons and such it wil make it look a lot better. Stil good tho. +5BITS

-----------------------------------
.hack
Sat Feb 07, 2004 2:43 pm


-----------------------------------
thank you :), I hope to have it released by sunday evening, but who knows.

It will look kind of repetitive seems how some other guy made on last night and put it up.

-----------------------------------
.hack
Sat Feb 07, 2004 2:52 pm


-----------------------------------
yea, I think I'm going to need a scroll bar or something to be able to croll with for this.. so any ideas? 

because it spawns choices down and you type in the choice number, but unfortunately the list is too long and gets cut off, so is ther any way to make a scroll bar type thing, or keyboard arrow pushes to scroll?

-----------------------------------
Maverick
Sat Feb 07, 2004 2:55 pm


-----------------------------------
Well if you dont wanna do that just make the screen bigger.

-----------------------------------
Cervantes
Sat Feb 07, 2004 4:29 pm


-----------------------------------
to make the screen bigger
View.Set ("graphics:x value;y value")

for a scroll bar, you can use the GUI one.  check out the help file on it.

-----------------------------------
.hack
Sat Feb 07, 2004 4:57 pm


-----------------------------------
Awesome, thanks for the help. Well I got everything besides the scoll bar working. my formulas work and my coding structure also works. here is the geist of my code so far(Probably should have used arrays, but I = dumbass)

%||Name: Stuart Montreuil                                                   ||
%||Class: ICS3M                                                             ||
%||Program File: StuartM51                                                  ||
%||Description: Large Conversion Program for Length,Weight,Temp             ||

%Other Variables
var Num : int
var Cho : int
var Amt : real
var Ans : real

%Code
put "Choose a Conversion Topic:"
put ""
put "1.","Length and Width Measurements"
put "2.","Solid Weight Measurements"
put "3.","Liquid Weight Measurements"
put "4.","Temperature"

if 1 = 1 then
put ""
put "Length And Width Measurment Conversions."
put ""
put "Choose Your Operation."
put ""

put "1.mm to centimetre."
put "2.mm to inch."
put "3.mm to feet."
put "4.mm to metre."
put "5.mm to kilometre."
put "6.mm to miles."
put " "
put "7.cm to mm."
put "8.cm to inch."
put "9.cm to feet."
put "10.cm to metre."
put "11.cm to kilometre."
put "12.cm to mile."
put " "
put "13.inch to mm."
put "14.inch to cm."
put "15.inch to feet."
put "16.inch to metre."
put "17.inch to kilometre."
put "18.inch to mile."
put " "
put "19.feet to mm."
put "20.feet to cm."
put "21.feet to inch"
put "22.feet to metre."
put "23.feet to kilometre."
put "24.feet to mile."
put ""
put "25.metre to mm."
put "26.metre to cm."
put "27.metre to inch."
put "28.metre to feet."
put "29.metre to kilometer."
put "30.metre to mile."
put ""
put "31.kilometre to mm."
put "32.kilometre to cm."
put "33.kilometre to inch."
put "34.kilometre to feet."
put "35.kilometre to metres."
put "36.kilometre to miles."
put ""
put "37.mile to mm."
put "38.mile to cm."
put "39.mile to inch."
put "40.mile to feet."
put "41.mile to metres."
put "42.mile to kilometres."
put ""
put ""
put "43. To Return To Conversion menu."
put "44. To Exit"
put "45. To Report Bug"
put ""
put ""
get Num

if Num = 1 then
put "Please enter Amount of mm."
get Amt
Ans := Amt/10
put "There is ",Ans," cm ","in ",Amt," mm"

elsif Num = 2 then
put "Please enter amount of mm."
get Amt
Ans := Amt/25.4
put "There is ",Ans,"inch(s) in ",Amt,"mm"

elsif Num = 3 then
put "Please enter amount of mm."
get Amt
Ans := Amt / 304.8
put "There is ",Ans," feet in ",Amt," mm"

elsif Num = 4 then
put "Please enter amount of mm."
get Amt
Ans := Amt / 1000
put "There is ",Ans," metre(s) in ",Amt," mm" 

elsif Num = 5 then
put "Please enter the amount of mm."
get Amt
Ans := Amt / 1000000
put "There is ",Ans, " kilometre(s) in ",Amt,"mm"


elsif Num = 6 then
put "Please enter amount of mm."
get Amt
Ans := Amt / 1609344
put "There is ",Ans, " mile(s) in ",Amt," mm"

elsif Num = 7 then
put "Please enter amount of cm."
get Amt
Ans := Amt / .1
put "there is ",Ans," millimetre(s) in ",Amt," cm"

elsif Num = 8 then 
put "Please enter amount of cm."
get Amt
Ans := Amt / 2.54
put "There is ",Ans," inch(s) in ",Amt," cm"

end if
end if



And so on and so forth for the rest of the options. I haven't done the section for weight and temperature yet, I'm jsut trying to get this working. Unfortunately I have to go outfor dinner tonight so this may but a delay on the release date.

-----------------------------------
Cervantes
Sat Feb 07, 2004 5:02 pm


-----------------------------------
whoa thats crazy... definately use the inital system where you had menus to determine what type of thing you wanted to convert, like temp or distance.

keep working on it! :)

-----------------------------------
white_dragon
Sat Feb 07, 2004 5:45 pm


-----------------------------------
wow, tat's soooooooo kool

-----------------------------------
.hack
Sat Feb 07, 2004 9:24 pm


-----------------------------------
Remember that good mood I was in? yea its ruined, apparently , I have been asking jeeves for  How many mm in a foot" and get the result, while I was doing feet to MM, thus having the equation backwards. Therefore everything to this point is FUBAR.

Looks like the release date will be pushed back some more.

-----------------------------------
recneps
Sun Feb 08, 2004 4:06 pm


-----------------------------------
maybe you could try it, 

"choose which you are starting with" 

then from there it pops up (say you chose mm)


1..mm->feet
2.mm->cm


and so on and so on for that specific starting

-----------------------------------
the_short1
Sun Feb 08, 2004 5:35 pm


-----------------------------------
EDIT: Removed Negative Comment
the_short1

-----------------------------------
Paul
Sun Feb 08, 2004 5:39 pm


-----------------------------------
Dude, even our teacher suggested we could do this kind of program, just cause someone has the same type of program doesnt mean they "stole" your idea.

-----------------------------------
shorthair
Sun Feb 08, 2004 9:44 pm


-----------------------------------
i like the mix of love and hate for his app ,it definatly made me laugh . I made one that was just for a few conversions ,

-----------------------------------
the_short1
Sun Feb 08, 2004 9:54 pm


-----------------------------------
EDIT: Removed Nasty comment...
the_short1

-----------------------------------
Paul
Sun Feb 08, 2004 9:59 pm


-----------------------------------
GUI? I don't see any GUI here, all I see is keyboard inputting.

-----------------------------------
.hack
Mon Feb 09, 2004 8:17 am


-----------------------------------
Yea you posted urs like a month ago. and it was at the bottom of the list.

And yea you caught me red handed, I stole YOUR idea despite everyone else whos made a unit converter, or when I could "stole" the idea for a better more useful program.

Get yur head out of ur ass b4 someone rams it farther up.

Ps: I don't like yours, not very organized, but good try and thanks for coming out.

Pps: here have some bits for learning how to orgranize your programs in one post.

http://www.ebaumsworld.com/forumfun/positive14.jpg

I also don't think there is need for a poll. People will use whatever one they find more useful.

-----------------------------------
the_short1
Mon Feb 09, 2004 11:26 am


-----------------------------------
ok....i will calm down now... im glad you took responsibility for that... sorry.... i was just a little frustated at the fact that i have no time to work on my programs lately... i wanted to have that GUI done already for Buttons for Each unit on measuremen, also showing the full name of the Abriviation somewhere else while your mouse hovered on button....  thx for bits..

And here is a hint:

http://www.digitaldutch.com/unitconverter/
because im a nice guy.... 

i like this website... only i would like it all in one....and for people not to have to surf the net... 