def METHOD_NAME(xp, xps, condition):
    """Strategy can generate indices with optional values."""
    strat = (
        xps.array_shapes(min_dims=1, max_dims=32)
        .flatmap(lambda s: xps.indices(s, allow_newaxis=True))
        .map(lambda idx: idx if isinstance(idx, tuple) else (idx,))
    )
    find_any(strat, condition)