[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: iptables -A or iptables -I?



On Tue, 2004-10-19 at 19:44 +0200, martin f krafft wrote:
> Uh, you should really read up on list/API design. This looks too
> much like Java or VB to me.

I said pseudocode. mallocs and other stuff were obfuscated for the sake
of the example ;)

> Appending to a n-linked list requires modification of n pointers.

It's the worst case (traversing a list with n elements)

> Inserting to a n-linked list requires modification of 2n pointers.

"Copying and Pasting" elements from one list to other, yes (it's 2n+1,
you're forgetting the inserted element). 

-- 
Juan Carlos Inostroza O.
Registered Linux User #246002
jci@tux.cl - http://www.tux.cl - http://foros.tux.cl
Blogging for fun _and_ profit : http://jci.codemonkey.cl
"We are just packets in the Internet of Life" -- UserFriendly



Reply to: