137. Single Number II
Given an array of integers, every element appears three times except for one. Find that single one.
Note:
Your algorithm should have a linear runtime complexity. Could you implement it without using extra memory?
记录32个bit每个bit出现的次数不能被3整除的几位加起来。
时间: 2024-10-22 06:27:16