【leetcode】136.(Easy)Single Number

解題思路: 我的想法:維護一個hashmap,記錄所有數字出現的次數 general的做法:使用XOR操作 提交代碼:維護map class Solution { public int singleNumber(int[] nums) { Map<Integer,Integer> map=new HashMap<Integer,Integer>();
相關文章
相關標籤/搜索