Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 how to get turing to interpret a string as a integer without using strint
Index -> Programming, Turing -> Turing Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
simonsben




PostPosted: Sat May 04, 2013 4:24 pm   Post subject: how to get turing to interpret a string as a integer without using strint

I am using Open Turing Editor version 1.2 (beta)


I am importing data from a .txt file then comparing a integer from the .txt file with a integer type variable. To allow this to happen im through strint it does not let me. I have tries using the cheat command however it interprets the number incorrectly so it is no help.

please help!
Sponsor
Sponsor
Sponsor
sponsor
Insectoid




PostPosted: Sat May 04, 2013 5:01 pm   Post subject: RE:how to get turing to interpret a string as a integer without using strint

Cheat doesn't convert strings to numbers. It looks at the raw data stored in the RAM and interprets that as a given type. "52" is not the same as 52.

Quote:
To allow this to happen im through strint it does not let me.


It does. You're probably doing something wrong. Strint is exactly what you should be using. I can't really help unless you post the error though.
theothercole




PostPosted: Sun May 05, 2013 11:49 pm   Post subject: Re: how to get turing to interpret a string as a integer without using strint

simonsben wrote:

I am using Open Turing Editor version 1.2 (beta)


I am importing data from a .txt file then comparing a integer from the .txt file with a integer type variable. To allow this to happen im through strint it does not let me. I have tries using the cheat command however it interprets the number incorrectly so it is no help.

please help!


Can you post the part of the code you are referring to?
Display posts from previous:   
   Index -> Programming, Turing -> Turing Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 3 Posts ]
Jump to:   


Style:  
Search: