当前位置:网站首页>20220607 others: sum of two integers
20220607 others: sum of two integers
2022-07-03 10:11:00 【Seeyouagain】
Title Description : Here are two integers a and b , Don't use Operator + and - , Calculates and returns the sum of two integers .
coded :
public static int getSum(int a, int b) {
int bit = (a & b) << 1;
int result = a ^ b;
if (bit != 0){
return getSum(result,bit);
}
return result;
}边栏推荐
- LeetCode - 508. Sum of subtree elements with the most occurrences (traversal of binary tree)
- Serial port programming
- QT setting suspension button
- Toolbutton property settings
- Vgg16 migration learning source code
- CV learning notes - camera model (Euclidean transformation and affine transformation)
- Deep learning by Pytorch
- openEuler kernel 技术分享 - 第1期 - kdump 基本原理、使用及案例介绍
- Simulate mouse click
- 使用密钥对的形式连接阿里云服务器
猜你喜欢

Swing transformer details-1

03 fastjason solves circular references

LeetCode - 1172 餐盘栈 (设计 - List + 小顶堆 + 栈))

Octave instructions

Opencv Harris corner detection

One click generate traffic password (exaggerated advertisement title)

CV learning notes alexnet

Opencv histogram equalization

Implementation of "quick start electronic" window dragging

LeetCode 面试题 17.20. 连续中值(大顶堆+小顶堆)
随机推荐
QT is a method of batch modifying the style of a certain type of control after naming the control
LeetCode - 1172 餐盘栈 (设计 - List + 小顶堆 + 栈))
Connect Alibaba cloud servers in the form of key pairs
Open Euler Kernel Technology Sharing - Issue 1 - kdump Basic Principles, use and Case Introduction
Google browser plug-in recommendation
Leetcode - 895 maximum frequency stack (Design - hash table + priority queue hash table + stack)*
MySQL root user needs sudo login
QT setting suspension button
CV learning notes alexnet
LeetCode - 673. Number of longest increasing subsequences
yocto 技術分享第四期:自定義增加軟件包支持
LeetCode - 673. 最长递增子序列的个数
4G module board level control interface designed by charging pile
01 business structure of imitation station B project
Leetcode-513: find the lower left corner value of the tree
Toolbutton property settings
What can I do to exit the current operation and confirm it twice?
Leetcode - 933 number of recent requests
Wireshark use
20220606数学:分数到小数