Re:What's wrong with this code, really?
by AlexandrB on Friday September 16, 2011 @09:14AM
(#3004291)
Why not just:
[ Parent
| on HN ]
Indeed. But the point I was making was that this hypothetical coder introduced more complexity by adding "i--;" whereas the code could equally well be fixed, in the same number of keystrokes, while reducing complexity, by removing "i++;".
Re:What's wrong with this code, really?
by masklinn on Friday September 16, 2011 @09:35AM
(#3004374)
Very inefficient on most array lists (but a very good idea on linked lists)
How many tabs do you use?
Less than 50?
Then don't worry about the optimization until you have to port it to a PDP10.
Re:What's wrong with this code, really?
by masklinn on Friday September 16, 2011 @03:58PM
(#3006038)
> Less than 50?
No, over nine thousands.
Re:What's wrong with this code, really?
by masklinn on Friday September 16, 2011 @03:58PM
(#3006037)
> Less than 50?
No, way more than that.
Re:What's wrong with this code, really?
by tlrobinson on Friday September 16, 2011 @11:07AM
(#3004721)
while (this.MyControl.TabPages.Count > 0)
{
this.MyControl.TabPages.Remove ( this.MyControl.TabPages.Count-1 );
}