LeetCode 371. Sum of Two Integers
来源:互联网 发布:电脑技术员必备软件 编辑:程序博客网 时间:2024/06/12 01:54
不用 + , - 运算符进行加法运算。
int getSum(int a, int b) { if(b==0) return a; int s = a^b; int w = (a&b)<<1; return getSum(s,w);}
没想到还能这样,算是见识了。
0 0
- LeetCode 371. Sum of Two Integers
- 371. Sum of Two Integers LeetCode OJ
- [Leetcode]371. Sum of Two Integers
- LeetCode - 371. Sum of Two Integers
- <LeetCode OJ> 371. Sum of Two Integers
- LeetCode 371. Sum of Two Integers
- leetcode 371. Sum of Two Integers
- leetcode 371.Sum of Two Integers
- LeetCode 371. Sum of Two Integers
- 371. Sum of Two Integers(Leetcode)
- leetcode 371. Sum of Two Integers
- 【leetcode】371. Sum of Two Integers【E】
- [leetcode] 371. Sum of Two Integers
- leetcode.371. Sum of Two Integers
- 371. Sum of Two Integers--LeetCode Record
- LeetCode—371. Sum of Two Integers
- Leetcode 371. Sum of Two Integers
- LeetCode 371. Sum of Two Integers
- 单个数码管指示逻辑电平
- 前端开发:从菜鸟到大牛的取经之路
- php脚本也能引发(Segmentation fault)段错误?
- 深度学习之对抗网络
- Java使用延迟初始化
- LeetCode 371. Sum of Two Integers
- [x]Face++的Python SDK学习
- php中isset()与empty的区别以及与0,NULL,FALSE的关系
- "=="和equals的区别
- 简单记忆化搜索
- 数据库设计——医药销售管理系统
- 华为机试-删除字符串中出现最少次数的字符
- 对状态模式的一点理解
- python2.7 Tkinter 入门