会算法的Dancer:有结果了吗楼主,我也是周五面的

0 点赞 评论 收藏
分享
2022-04-20 13:34
合肥工业大学 算法工程师 0 点赞 评论 收藏
分享
牛客81939570...:hhh是第一次面试吗?感觉你好紧张

0 点赞 评论 收藏
分享

0 点赞 评论 收藏
分享
携程24秋招内推官:我一开始第一题就不小心习惯性快捷键点出去三次 后面做的心里压力很大

0 点赞 评论 收藏
分享
在努力存钱的袋鼠很用...:删数那题可以这么做么
#include<iostream>
(5488)#include<set>
using namespace std;
set<int> s;
const int N = 1e4+10;
int main() {
int n ;
cin>>n;
while (n--) {
int c;
cin>>c;
if(s.find(c) == s.end()) {
s.insert(c);
}
else {
s.erase(c);
int x = c<<1;
while(s.find(x) != s.end()){
x<<1;
}
s.insert(x);
}
}
cout<<*s.rbegin()<<endl;
}

0 点赞 评论 收藏
分享
说等下个版本吧的马后...:老哥面的哪个部门?

0 点赞 评论 收藏
分享
创作者周榜
更多
关注他的用户也关注了: