On Jun 8, 4:04 am, Lie <[EMAIL PROTECTED]> wrote: > On Jun 8, 8:56 am, Mensanator <[EMAIL PROTECTED]> wrote: > > > > > > > On Jun 7, 8:22�pm, John Salerno <[EMAIL PROTECTED]> wrote: > > > > Mensanator wrote: > > > > What I DID say was that how the builtins actually > > > > work should be understood and it APPEARED that the > > > > OP didn't understand that. Maybe he understood that > > > > all along but his example betrayed no evidence of > > > > that understanding. > > > > Well, the truth is that I know zip truncates to the shorter of the two > > > arguments, > > > Ok, sorry I thought otherwise. > > > > and also in my case the two arguments would always be the > > > same length. > > > Yes, because you're controlling the source code. > > But since lists are mutable, source code literals > > don't always control the length of the list. > > Since when source code literals ever control the length of a list?
Isn't score_costs = [0, 1, 1, 1, 1, 1, 1, 2, 2, 3, 3] considered a literal? > What controls the length of the list is the semantic meaning of the > list, Wha do you mean by that? The list contains 11 objects. How could the length be any different? > in some cases it just makes no sense that the list would ever > have different length. And in such case there won't be any problem, will there? Is that a good habit to teach a newbie? To write code that only works for special cases? > > (snip)- Hide quoted text - > > - Show quoted text - -- http://mail.python.org/mailman/listinfo/python-list