CodingLife


  • Home

  • Archives

  • Tags

  • Search

Algorithm SnowFlake

Posted on 2021-05-12

SnowFlake 在分布式系统中希望能够生成一个随时间增长的唯一 ID,这时可以用 Snow Flake(雪花算法)实现。

Read more »

Go 单例模式 sync.Once

Posted on 2021-05-10

Go 的单例可以用 sync.Once 简单实现:

Read more »

Java LongAdder

Posted on 2021-05-09

Java jdk8 新增了原子操作类 LongAdder,它对标 AtomicLong,提高了多 CPU 并发下的效率,在这里记录一下。

Read more »

Binary Search, Lower Bound, Upper Bound

Posted on 2021-05-05

BinarySearch “Although the basic idea of binary search is comparatively straightforward, the details can be surprisingly tricky.” – Donald Knuth

Read more »

Algorithm Random

Posted on 2021-05-04

记录 Random 的算法实现

Read more »

Algorithm Reservoir Sampling(蓄水池抽样)

Posted on 2021-05-03

Reservoir Sampling Reservoir Sampling(蓄水池抽样)可以简单的从大量流式数据中随机抽取指定数量的样本,并且保证样本被取到的概率相同,适合大数据分析场景。

Read more »

Algorithm Sort

Posted on 2021-05-02

记录 Sort 的算法实现

Read more »

Algorithm Segment Tree

Posted on 2021-05-02

记录 Segment Tree 的算法实现

Read more »

Algorithm Minimax

Posted on 2021-05-02

记录 Minimax 的算法实现

Read more »

Algorithm Line Sweep

Posted on 2021-05-02

记录 Line Sweep 的算法实现

Read more »
1 … 9 10 11 … 31
CodeHunter2006

CodeHunter2006

这里包括一些技术经验总结、生活随想和其他...

304 posts
11 categories
85 tags
RSS
GitHub
© 2025 CodeHunter2006
Powered by Jekyll
Theme - NexT.Muse