Search
πŸ₯‰

Richest Customer Wealth

Created
2022/01/31 03:17
문제 번호
1672
μΉ΄ν…Œκ³ λ¦¬
Array
Matrix

Code

제좜 λ‚ μ§œ
μ‹œκ°„
λ©”λͺ¨λ¦¬
2022/01/31
0 ms
3.1 MB
// 1672. Richest Customer Wealth // // https://leetcode.com/problems/richest-customer-wealth/ // maximumWealth function returns the maximum value of the person's wealth. func maximumWealth(accounts [][]int) int { answer := 0 for _, person := range accounts { acc := 0 for _, account := range person { acc += account } if answer < acc { answer = acc } } return answer }
Go
볡사