![](https://img-blog.csdnimg.cn/20201014180756919.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
学习笔记
要坚持写博客
这个作者很懒,什么都没留下…
展开
-
机器学习画图工具(1)
pd.to_datetime()//表示把那个日期的格式转化成上图的日期的格式。import matplotlib.pyplot as plt //matplotlib.pyplot画可视化的库plt.plot(x,y) //画x轴,y轴plt.xticks(rotation=45)//表示x下面的数字倾斜45°plt.show() //显示plt.xlabel('month')plt.ylabel('Un……')plt.title('Mon……')plt.figure() //.原创 2022-01-27 17:40:36 · 1718 阅读 · 0 评论 -
开始记录机器学习的库函数——Numpy
import numpyworld = numpy.genfromtxt("world.txt",delimiter=",",dtype=str)//第一个参数是要读取文件的位置,第二个参数是文件内分隔的符号,第三是用什么样子的类型去读取print(type(world)) //当前变量是什么结构print(help(numpy.genfromtxt)) //打印一下帮助文档。也就是这个函数的参数怎么传啥的。vector = numpy.array([1,2,3,4])//是创建一个array数组原创 2022-01-24 11:22:06 · 967 阅读 · 0 评论 -
android 图库
阿里巴巴有个免费的icon网站叫iconfont原创 2021-10-04 18:46:11 · 424 阅读 · 0 评论 -
我的数论练习
传送门原创 2021-07-27 20:29:45 · 120 阅读 · 0 评论 -
三个函数ceil()、floor()、round()
double x;int fx = floor(x);//向下取整函数int cx = ceil(x);//向上取整函数int rx = round(x);//四舍五入函数原创 2021-06-03 16:13:37 · 98 阅读 · 0 评论 -
没总结的二分模板
借鉴于:此处最大值最小问题。int bsearch_1(int l, int r){ while (l < r) { int mid = l + r >> 1; if (check(mid)) r = mid; else l = mid + 1; } return l;}最小值最大问题int bsearch_2(int l, int r){ while (l < r) {原创 2021-07-16 11:19:46 · 54 阅读 · 0 评论 -
求因数个数
int count(int n){ int s = 1; for(int i = 2 ; i * i <= n ; i++) { if(n % i == 0) { int a = 0 ; while(n % i == 0) { n /= i; a++; } s =原创 2021-07-13 14:35:03 · 113 阅读 · 0 评论 -
集训记录思考不到位没A掉的题
C题原创 2021-07-10 08:39:17 · 80 阅读 · 0 评论 -
Atcoder abc 208场 A~D
Rolling Dice:A题思路:可以摔a次骰子,得到的最小值肯定是都为1时,得到的最大值肯定是都为6时,在这之间都能得到。#include<cstdio>#include<cstring>#include<algorithm>#include<map>#include<math.h>#include<iostream>#include<cmath>#include<queue>#inclu原创 2021-07-04 22:37:11 · 258 阅读 · 1 评论 -
注意0x3f3f3f3f的范围!!!
0x3f3f3f3f的十进制是1061109567,是10^9级别的,居然不知道这个被卡了我差不多一小时,得记住了!!!int范围的无穷大!原创 2021-06-13 08:25:14 · 187 阅读 · 0 评论 -
atcoder arc 122 a~b题Many Formulae、Insurance
A题链接题目大意:不能存在两个及两个以上的减号,所有满足条件的式子之和。题目思路:当时考试想到一半,就感觉编码能力不太会,然后就没做,首先我们定义dp[N][2],这种选或不选的问题,一般都是这样定义的;其中:dp[i][0]表示第i个为+,(这里我们可以把每个数看成是一个符号,自己在第一个数前面加了一个+。)因为这样看比较容易一点。dp[i][1]表示第i个为-;当时就想到这里。但是没去写…………这时候成功了一半了,然后我们还需要定义一个cnt[i][2]去记录数量,cnt[i][0]表示第i原创 2021-06-13 07:46:59 · 340 阅读 · 0 评论 -
自我感觉比较经典的题目
题目链接题解一:题解链接原创 2021-06-04 17:45:29 · 82 阅读 · 0 评论 -
一些竞赛模板
返回因子数ll dcpCount(ll x){ ll ans=1; for(ll i=2;i*i<=x;i++) { if(x%i==0) { ll temp=0; while(x%i==0) { x/= i; temp++; } ans*=(temp+1);原创 2021-06-06 17:51:22 · 66 阅读 · 0 评论