-
[leetcode 75-11] Sum of Two IntegersAlgorithm 2023. 1. 30. 22:26
https://leetcode.com/problems/sum-of-two-integers
Sum of Two Integers - LeetCode
Sum of Two Integers - Given two integers a and b, return the sum of the two integers without using the operators + and -. Example 1: Input: a = 1, b = 2 Output: 3 Example 2: Input: a = 2, b = 3 Output: 5 Constraints: * -1000 <= a, b <= 1000
leetcode.com
class Solution: def getSum(self, a: int, b: int) -> int: return a+b
'Algorithm' 카테고리의 다른 글
[leetcode 75-13] Counting Bits (1) 2023.01.30 [leetcode 75-12] Number of 1 Bits (0) 2023.01.30 [leetcode 75-8] Search in Rotated Sorted Array (0) 2023.01.30 [leetcode 75-7] Find Minimum in Rotated Sorted Array (0) 2023.01.29 [leetcode 75-6] Maximum Product Subarray (0) 2023.01.29