Thread: randomstring2
View Single Post
  #6  
Old 12-31-2008, 03:35 AM
LoneAngelIbesu LoneAngelIbesu is offline
master of infinite loops
LoneAngelIbesu's Avatar
Join Date: May 2007
Location: Toldeo, Ohio
Posts: 1,049
LoneAngelIbesu has a spectacular aura aboutLoneAngelIbesu has a spectacular aura about
Send a message via AIM to LoneAngelIbesu
Quote:
Originally Posted by Tigairius View Post
No upside to using a string, I just didn't feel like doing temp.source = {"A", "B", "C", etc};
I think it's generally bad practice to use a while() loop where a for() loop can be used, and right now it doesn't look like you have any loop protection, so if you input incorrect parameters you can break the loop limit.
I did use a for() loop, originally. However, that results in temp.i increasing, even though nothing is added to temp.output. That results in outputs that aren't the length defined by temp.limit.

Also, I have no clue what "loop protection" is. A search leads only to this topic.
__________________
"We are all in the gutter, but some of us are looking at the stars."
— Oscar Wilde, Lady Windermere's Fan
Reply With Quote