OctopusLian / leetcode-solutions

LeetCode,LintCode,牛客网,企业题库,《Sword to Offer》,《Cracking the Coding Interview》题解
MIT License
4 stars 4 forks source link

每日一题:谈谈java中的LongAdder和LongAccumulator的相同点和不同点 #186

Closed OctopusLian closed 2 years ago

OctopusLian commented 3 years ago

https://my.oschina.net/u/4553401/blog/4685033 简单回答: 相同点:都是多个单元操作。 不同点:LongAdder相加,LongAccumulator自定义计算规则。