remove = lambda list, values:[x for x in list if not x in values]
def remove(integers, values):return list(filter(lambda x: x not in values,integers))- remove = lambda list, values:[x for x in list if not x in values]
@test.describe("Basic Test Cases") def basic_test_cases(): test.assert_equals(remove([], []), []) test.assert_equals(remove([1, 1, 3, 5, 7, 7, 7, 9, 10, 10], [1, 7, 9]), [3, 5, 10, 10]) test.assert_equals(remove([1, 2, 3, 4, 5], [2, 4]), [1, 3, 5])
- @test.describe("Basic Test Cases")
- def basic_test_cases():
- test.assert_equals(remove([], []), [])
- test.assert_equals(remove([1, 1, 3, 5, 7, 7, 7, 9, 10, 10], [1, 7, 9]), [3, 5, 10, 10])