Author |
Message |
Masta_911
|
Posted: Sun Jan 14, 2007 11:19 am Post subject: Indent Problem |
|
|
Iam having this little problem with indenting. everytime i presss F2 it gives me this error message:
INDENT Failed
Not enough memory to indent file
PLz help |
|
|
|
|
![](images/spacer.gif) |
Sponsor Sponsor
![Sponsor Sponsor](templates/subSilver/images/ranks/stars_rank5.gif)
|
|
![](images/spacer.gif) |
CodeMonkey2000
|
Posted: Sun Jan 14, 2007 11:44 am Post subject: RE:Indent Problem |
|
|
that means that your program is too big for the editor to indent |
|
|
|
|
![](images/spacer.gif) |
Masta_911
|
Posted: Sun Jan 14, 2007 11:52 am Post subject: RE:Indent Problem |
|
|
no its jus 1 line dats 661 colomns long
its somthing like
if z = 100 and k = 100 and.......
is there a way to shorten that line and maybe put that line in 3 or 4 lines for example
if z = 100 and then continue that same line in the next line after like 100 colomns
if i take that line offf it indents perfectly |
|
|
|
|
![](images/spacer.gif) |
CodeMonkey2000
|
Posted: Sun Jan 14, 2007 12:05 pm Post subject: RE:Indent Problem |
|
|
Sorry I don't understand what you are saying, can you please post the code segant that is long? |
|
|
|
|
![](images/spacer.gif) |
Masta_911
|
Posted: Sun Jan 14, 2007 12:10 pm Post subject: Re: Indent Problem |
|
|
code: |
if ro = false and ro1 = false and ro2 = false and ro3 = false and ro4 = false and ro5 = false and ro6 = false and ro7 = false and ro8 = false and ro9 = false and ro10 = false and ro11 = false and ro12 = false and ro13 = false and ro14 = false and ro15 = false and ro16 = false and ro17 = false and ro18 = false and ro19 = false and ro20 = false and ro21 = false and ro22 = false and ro23 = false and ro24 = false and ro25 = false and ro26 = false and ro27 = false and ro28 = false and ro29 = false and ro30 = false and ro31 = false and ro32 = false and ro33 = false and ro34 = false then
|
heres the if statement dats 2 loooooong
and i tried making it an array it not going to work for my program then
hope this helps you understand it better |
|
|
|
|
![](images/spacer.gif) |
CodeMonkey2000
|
Posted: Sun Jan 14, 2007 12:16 pm Post subject: Re: Indent Problem |
|
|
At every few "and"s you can hit enter. like: code: | if ro = false and ro1 = false and ro2 = false
and ro3 = false and ro4 = false and ro5 = false
and ro6 = false and ro7 = false and ro8 = false
and ro9 = false and ro10 = false and ro11 = false
and ro12 = false and ro13 = false and ro14 = false
and ro15 = false and ro16 = false and ro17 = false
and ro18 = false and ro19 = false and ro20 = false
and ro21 = false and ro22 = false and ro23 = false
and ro24 = false and ro25 = false and ro26 = false
and ro27 = false and ro28 = false and ro29 = false
and ro30 = false and ro31 = false
and ro32 = false and ro33 = false and ro34 = false then | that should work now.can you try to use arrays and for loops for this? |
|
|
|
|
![](images/spacer.gif) |
Masta_911
|
Posted: Sun Jan 14, 2007 12:21 pm Post subject: RE:Indent Problem |
|
|
thanks a lot that worksssssss
i did try buh maybe i am not good with arrays |
|
|
|
|
![](images/spacer.gif) |
[Gandalf]
![](http://compsci.ca/v3/uploads/user_avatars/189297994e4c716fec7f1.png)
|
Posted: Sun Jan 14, 2007 12:23 pm Post subject: Re: Indent Problem |
|
|
Dear goodness... Of course you should be using an array! The most obvious way is:
Turing: | var ro : array 0 .. 34 of boolean
for i : 0 .. upper (ro )
ro (i ) := false
end for
var allFalse : boolean := true
for i : 0 .. upper (ro )
if ro (i ) then
allFalse := false
exit
end if
end for
if allFalse then
put "Hi"
else
put "Bye"
end if |
|
|
|
|
|
![](images/spacer.gif) |
Sponsor Sponsor
![Sponsor Sponsor](templates/subSilver/images/ranks/stars_rank5.gif)
|
|
![](images/spacer.gif) |
|