On Thursday, October 18, 2018 at 9:43:34 AM UTC-4, Jakub Sliacan wrote: > > I thought edges are always listed sorted, i.e. x <= y in (x,y). Can you > produce an example when this is not the case? > > On Thursday, 18 October 2018 15:35:43 UTC+2, David Einstein wrote: >> >> Given an undirected graph g, and two vertices v1 and v2 such that there >> is an edge connecting them, is there a simple way to figure out which one >> of (v1, v2) or (v2, v1) will be the edge that occurs in >> g.edges(labels=False)? >> >> >> No, I cannot, but as we transfer to Python 3 it is no longer guaranteed that vertices will be sortable, and so tuple(sorted([v1,v2])) should be avoided.
-- You received this message because you are subscribed to the Google Groups "sage-support" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at https://groups.google.com/group/sage-support. For more options, visit https://groups.google.com/d/optout.
