首页
题库
面试
求职
学习
竞赛
More+
所有博客
搜索面经/职位/试题/公司
搜索
我要招人
去企业版
登录 / 注册
但求八月九月好运!
亳州职业技术学院
2020届
C++工程师
关注
私信
加入黑名单
举报TA
首页
刷题
圈子
项目
笔记
基本资料
真题试卷
在线编程
心理测试
回答的问题(139)
滑动窗口的最大值
1
//用两个迭代器搞定 class Solution { public: vector<int> maxInWindows(vector<int>& num, unsigned int size) { vector<int&g...
发表于 2019-04-22 21:34:45
数据流中的中位数
0
class Solution { public: void Insert(int num) { arr.push_back(num); return ; } double GetMedian() { sort...
发表于 2019-04-22 21:15:33
二叉树的最小深度
1
//其实不是很明白,如果一个根节点的左右子树存在一个为空,那么它的最小深度不就是1吗 class Solution { public: int run(TreeNode *root) { if(root==nullptr) return 0; int l=ru...
发表于 2019-04-22 21:07:42
对称的二叉树
0
class Solution { public: bool isSymmetrical(TreeNode* pRoot) { if(pRoot==nullptr) return true; return isSame(pRoot->left,...
发表于 2019-04-21 08:52:39
删除链表中重复的结点
1
/* struct ListNode { int val; struct ListNode *next; ListNode(int x) : val(x), next(NULL) { } }; */ class Solution { public: ...
发表于 2019-04-20 21:06:09
链表中环的入口结点
0
class Solution { public: ListNode* EntryNodeOfLoop(ListNode* pHead) { if(pHead==nullptr) return nullptr; bool isCircle=false...
发表于 2019-04-20 11:37:13
构建乘积数组
0
//在这说明一下...O(n)的都是大佬 class Solution { public: vector<int> multiply(const vector<int>& A) { vector<int>res(A.size(...
发表于 2019-04-19 11:47:26
数组中重复的数字
4
//duplication只有一个值,居然还用指针,醉了 bool duplicate(int numbers[], int length, int* duplication) { if(length<=0) return false; int inde...
发表于 2019-04-19 11:34:10
把字符串转换成整数
0
class Solution { public: int StrToInt(string str) { int res=0; bool flag=true; if(str.size()<=0) return 0; if(s...
发表于 2019-04-19 11:16:28
孩子们的游戏(圆圈中最后剩下的数)
0
class Solution { public: int LastRemaining_Solution(int n, int m) { if(!n||!m) return -1; int hash[n]; memset(hash,0,s...
发表于 2019-04-18 14:40:51
首页
上一页
7
8
9
10
11
12
13
14
下一页
末页
扫描二维码,关注牛客网
意见反馈
下载牛客APP,随时随地刷题