摘要:
链接:https://leetcode-cn.com/problems/climbing-stairs/ 代码 class Solution { public: int climbStairs(int n) { vector<int> f(n + 1); f[0] = 1, f[1] = 1; fo 阅读全文
posted @ 2020-07-11 10:07
景云ⁿ
阅读(58)
评论(0)
推荐(0)
摘要:
链接:https://leetcode-cn.com/problems/sqrtx/ 代码 class Solution { public: int mySqrt(int x) { int l = 0, r = x; while (l < r) { int mid = (l + 1ll + r) / 阅读全文
posted @ 2020-07-11 10:03
景云ⁿ
阅读(74)
评论(0)
推荐(0)
摘要:
链接:https://leetcode-cn.com/problems/text-justification/ 代码 class Solution { public: vector<string> fullJustify(vector<string>& words, int maxWidth) { 阅读全文
posted @ 2020-07-11 09:59
景云ⁿ
阅读(57)
评论(0)
推荐(0)
摘要:
链接:https://leetcode-cn.com/problems/add-binary/ 代码 class Solution { public: string addBinary(string a, string b) { if (a.size() < b.size()) swap(a, b) 阅读全文
posted @ 2020-07-11 09:38
景云ⁿ
阅读(87)
评论(0)
推荐(0)

浙公网安备 33010602011771号