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

Username:   Password: 
 RegisterRegister   
 Keep on getting this indent error
Index -> Programming, Turing -> Turing Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
dhyanp11




PostPosted: Wed Mar 09, 2016 9:32 pm   Post subject: Keep on getting this indent error

http://pastebin.com/Eg7v1rmW
Sponsor
Sponsor
Sponsor
sponsor
Dreadnought




PostPosted: Wed Mar 09, 2016 10:47 pm   Post subject: Re: Keep on getting this indent error

As I explained (perhaps not clearly enough) in your previous post, you should be writing your if statements as
Turing:
if [condition1] then
    [...]
elsif [condition2] then
    [...]
else
    [...]
end if

otherwise you need extra end ifs
Turing:
if [condition1] then
    [...]
else
    if [condition2] then
        [...]
    else
        [...]
    end if
end if


And of course you can use multiple elsifs in a row.
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  [ 2 Posts ]
Jump to:   


Style:  
Search: