摘要:
问题: Given an array of numbers nums, in which exactly two elements appear only once and all the other elements appear exactly twice. Find the two eleme 阅读全文
摘要:
问题:Given an array nums, write a function to move all 0's to the end of it while maintaining the relative order of the non-zero elements. 思考:开始想通过两层for 阅读全文
摘要:
问题:Given an array of integers, every element appears twice except for one. Find that single one. 思考:运用双循环,微循环循环待比较数字,内层比较。增加一个flag表明是否匹配。 知识:flag的使用,以 阅读全文
摘要:
问题:You are playing the following Nim Game with your friend: There is a heap of stones on the table, each time one of you take turns to remove 1 to 3 s 阅读全文