redis.rpush("mylist", "one", "two", "three", "two", "one") assert redis.lrem("mylist", 2, "two") == 2 assert redis.lrange("mylist", 0, -1) == ["one", "three", "one"]
Remove the first count occurrences of an element from a list.
count
Was this page helpful?