首页
题库
面试
求职
学习
竞赛
More+
所有博客
搜索面经/职位/试题/公司
搜索
我要招人
去企业版
登录 / 注册
梦飞1014
中山大学
2020届
Java工程师
关注
私信
加入黑名单
举报TA
首页
刷题
圈子
项目
笔记
基本资料
真题试卷
在线编程
心理测试
回答的问题(18)
矩形覆盖
0
class Solution { public: int rectCover(int number) { if(number == 0) return 0; int *count = new int[number + 1]; count[0] ...
发表于 2019-03-16 08:51:19
跳台阶扩展问题
0
class Solution { public: int jumpFloorII(int number) { int res = 1; for(int i = 0; i < number - 1; i++){ res *= 2; ...
发表于 2019-03-16 08:40:35
跳台阶
0
class Solution { public: int jumpFloor(int number) { int* count = new int[number + 1]; count[0] = 1; count[1] = 1; ...
发表于 2019-03-16 08:25:04
斐波那契数列
0
class Solution { public: int Fibonacci(int n) { if(n == 0) return 0; if(n == 1 || n == 2) return 1; return Fibonacci(n - 1...
发表于 2019-03-15 22:00:02
旋转数组的最小数字
0
class Solution { public: int minNumberInRotateArray(vector<int> rotateArray) { if(rotateArray.size() == 0) return 0; for(int...
发表于 2019-03-15 21:55:41
重建二叉树
0
/** * Definition for binary tree * struct TreeNode { * int val; * TreeNode *left; * TreeNode *right; * TreeNode(int x) : val(x),...
发表于 2019-03-15 21:50:17
用两个栈实现队列
0
class Solution { public: void push(int node) { stack1.push(node); } int pop() { if(stack2.empty()){ while(!sta...
发表于 2019-03-15 21:49:46
二维数组中的查找
0
这里的思路跟以上大部分的差不多,只不过是从左下角开始的,而且不是采用简单的遍历,而是加上了二分查找减少查找次数,提高效率。 public class Solution { static boolean find(int target, int[][] array) { in...
发表于 2019-03-12 12:46:16
首页
上一页
1
2
下一页
末页
扫描二维码,关注牛客网
意见反馈
下载牛客APP,随时随地刷题