Learn R Programming

rredis (version 1.7.0)

redisSPop: Remove and return an element from a set.

Description

Remove and return an element, chosen at random, from the specified set.

Usage

redisSPop(set, ...)

Arguments

set
The set name (character).
...
Optional additional arguments. Specify raw=TRUE to skip de-serialization of the data.

Value

not exist.

References

http://redis.io/commands

See Also

redisSAdd

Examples

Run this code
## Not run: 
# redisConnect()
# redisSAdd('set',runif(2))
# redisSAdd('set',runif(3))
# redisSAdd('set',runif(4))
# redisSPop('set')
# redisSPop('set')
# redisSPop('set')
# redisSPop('set')
# ## End(Not run)

Run the code above in your browser using DataLab