Rob Beezer
නොකියවූ,2010 ජූනි 5, 23.49.402010-06-05Sign in to reply to author
Sign in to forward
ඔබට මෙම සමූහයෙහි පණිවිඩ මැකීමට අවසරය නැත
පණිවිඩය අයථා පරිහරණයක් ලෙස වාර්තා කරන්න
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
සිට sage-devel
Consider
sage: G = SymmetricGroup(2)
sage: elements = G.list()
sage: elements.remove(G("()"))
sage: K = SymmetricGroup(2)
sage: K.list()
[(1,2)]
Notice K lacks the identity permutation. I'd at least expect K to
be a "new" undisturbed version of S_2.
Is there some overly-aggressive caching here? Should there be some
protection against the above? Or am I missing something?
Using elements = copy(G.list()) causes K to have all of its
elements, but the docstring for list() doesn't say anything about
making a copy, or being an "in-place" version, etc.
Rob