首页
题库
公司真题
专项练习
面试题库
在线编程
面试
面试经验
AI 模拟面试
简历
求职
学习
课程
专栏·文章
竞赛
搜索
我要招人
发布职位
发布职位、邀约牛人
更多企业解决方案
在线笔面试、雇主品牌宣传
登录
/
注册
小帅哥HLB
获赞
12
粉丝
0
关注
3
看过 TA
2
四川大学
2024
Java
IP属地:四川
暂未填写个人简介
私信
关注
拉黑
举报
举报
确定要拉黑小帅哥HLB吗?
发布(5)
刷题
小帅哥HLB
2022-03-11 11:39
四川大学 计算机类
题解 | #浮点数加法#
">#include<cstdio> #include<string> #include<algorithm> using namespace std; int main(){ string str1,str2; while(cin>>str1>>str2) { int pos1 = str1.find("."); int pos2 = str2.find("."); string x1=str1.substr(0,pos1);//保留str1的整数部分 ...
0
点赞
评论
收藏
转发
小帅哥HLB
2022-03-10 21:33
四川大学 计算机类
题解 | #子串计算#
">#include<string> #include<map> using namespace std; int main() { string s; cin >> s; map<string, int> m; //构建散列表 for (int i = 0; i < s.size(); i++) { for (int j = 0; j <= i; j++) { m[s.substr(j, i-j+1)]++; } ...
0
点赞
评论
收藏
转发
小帅哥HLB
2022-03-10 18:42
四川大学 计算机类
题解 | #位操作练习#
">#include<cstdio> #include<string> #include<algorithm> using namespace std; string IntToChar(int a) //十进制转化为二进制 { string str = ""; while(a != 0) { str += a % 2 + '0'; a = a / 2; } while(str.size() < 16) str += '0'; //逆置字符串 r...
0
点赞
评论
收藏
转发
小帅哥HLB
2022-03-10 10:58
四川大学 计算机类
题解 | #放苹果#
#include <cstdio> #include <string> #include <algorithm> using namespace std; //求m个苹果放n个盘子中的方法数 int ways(int m, int n) { //边界条件 if (m == 0)return 1; if (n == 0)return 0; /*m<n时,必定有n-m个盘子空着,去掉它们不影响摆放数目。 m>=n时,分两种情况:至少有一个盘子空着;所有盘子都有苹果,从每个盘子中拿一个苹果不影响放法。*/ if (m < n) { ...
0
点赞
评论
收藏
转发
小帅哥HLB
2022-02-17 16:06
四川大学 计算机类
八皇后
#include <iostream> #include <vector> #include <algorithm> using namespace std; vector<int> A; int Q[8][8] = {0}; //因为是从上往下,当前行下面不会有元素,所以只需要判断左上角和右下角 bool Judge(int row, int col) { for(int i = 0; i < 8; ++i) //判断列 { if(Q[i][col] == 1) return ...
0
点赞
评论
收藏
转发
1
工具箱
TA的圈子
暂未加入圈子
TA的圈子
TA的笔记
暂无笔记
TA的笔记
登录
0
天
已登录
0
天
连续登录
0
人
今日访客
牛客网
牛客企业服务