def ThingsToChooseFrom(ws):
    """Yields two-tuples of things to choose from, the second being weight."""
    for element in ws.elements:
        yield element, 20
    for gp in ws.groups:
        yield gp, gp.strength
