摘要: [LeetCode] Anagrams Given an array of strings, return all groups of strings that are anagrams. Note: All inputs will be in lower-case. 思路: Anagrams指几个 阅读全文
posted @ 2018-09-15 23:37 鸭子船长 阅读(261) 评论(0) 推荐(0)
摘要: 题目描述 Implement pow(x, n). AC: class Solution { public: double pow(double x, int n) { if(x == 0 && n == 0) return 1; if(x == 0) return 0; if(n == 0) re 阅读全文
posted @ 2018-09-15 23:25 鸭子船长 阅读(238) 评论(0) 推荐(0)
摘要: N-Queens The n-queens puzzle is the problem of placing n queens on an n×n chessboard such that no two queens attack each other. Given an integer n, re 阅读全文
posted @ 2018-09-15 23:10 鸭子船长 阅读(302) 评论(0) 推荐(0)