首页
注册
登录
V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请
登录
›
Redis
›
Redis 入门指南
›
phpRedisAdmin
›
Deploy Redis on Ubuntu or Debian
V2EX
›
Redis
为什么 Redis 的 SRANDMEMBER key 的时间复杂度为 O(1)?
JasonLaw
·
2020-11-16 10:02:00 +08:00
· 3100 次点击
这是一个创建于 1255 天前的主题,其中的信息可能已经有所发展或是发生改变。
Redis
key
复杂
srandmember
5 条回复
•
2020-11-16 12:05:40 +08:00
1
lithium4010
2020-11-16 10:35:00 +08:00
https://github.com/redis/redis/blob/unstable/src/t_set.c#L630
2
shiji
2020-11-16 10:46:05 +08:00
@
lithium4010
感叹 他们的注释写的真好
3
wysnylc
2020-11-16 11:38:30 +08:00
@
shiji
#2 好的代码不需要注释,代码即是注释
4
ianEros
2020-11-16 12:01:42 +08:00
完蛋 看不懂。。。。
5
gstqc
2020-11-16 12:05:40 +08:00 via Android
@
wysnylc
Perl 程序员想打人🐶
关于
·
帮助文档
·
博客
·
API
·
FAQ
·
我们的愿景
·
实用小工具
·
3524 人在线
最高记录 6543
·
Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 28ms ·
UTC 10:47
·
PVG 18:47
·
LAX 03:47
·
JFK 06:47
Developed with
CodeLauncher
♥ Do have faith in what you're doing.