3 ms·
I think my job is safe. def all_odd_prime_elements(sequence): """Returns every odd prime element of the sequence.""" return [x for x in seq
by recursive 4y ago
I think my job is safe.
def all_odd_prime_elements(sequence):
"""Returns every odd prime element of the sequence."""
return [x for x in sequence if x % 2 == 1]
def all_even_prime_elements(sequence):
"""Returns every even prime element of the sequence."""
return [x for x in
- DarmokJalad1701 4y agoYou can increase the number of tokens to be generated in "Advanced Settings"
- varunkmohan 4y agoThat's not the issue here, it's just saying any odd number is prime, which is false
- klohto 4y agoI’m not sure about job safety for both of you since the function doc says what it is and it’s definitely not searching for primes :)
- matt123456789 4y ago“Every odd prime element” Code does not check primality, only oddness.