直接判断单价和单买就可以 #include<bits/stdc++.h> #include<string.h> using namespace std; #define rep(i,j,k) for(LL i=(j); i<(k); ++i) #define pb push_back #define ...
分类:
其他好文 时间:
2020-06-26 10:58:28
阅读次数:
67
摘要 这个官方文档一段对MySQL内核分析的一个向导。是对MySQL一条insert语句写入到MySQL数据库的分析。但是,对于MySQL 5.7版本来说,基本上都是写入到innodb引擎。但也还是有借鉴意义,大的框架没有太大变化。后面的文档,会通过mysqld --debug 和gdb等工具,通过 ...
分类:
数据库 时间:
2020-06-26 00:59:23
阅读次数:
152
#!/bin/bash #备份数据库 dir=/usr/share/nginx/html/project/ssh/backup/`date +%Y%m%d` mysqldb=test musqluser=root mysqlpwd=123456 mysqlicmd=/usr/bin/mysqldum ...
分类:
数据库 时间:
2020-06-25 21:46:08
阅读次数:
102
自带健康检查配置 upstream backend{ server 127.0.0.1:8020 max_fails=2 fail_timeout=40s; #在40s 时间内有两次后端服务连接失败就判断后端服务不可用 server 127.0.0.1:8021 max_fails=1 fail_t ...
分类:
其他好文 时间:
2020-06-25 19:33:26
阅读次数:
63
print assert #优雅点,效果同print log日志:最强大 https://www.cnblogs.com/yyds/p/6901864.html import logging #允许指定记录信息的级别,有debug,info,warning,error等几个级别 LOG_FORMAT ...
分类:
其他好文 时间:
2020-06-25 19:21:49
阅读次数:
57
Iterator对象在foreach循环的时候只能使用自己的remove/add方法,如果使用了集合的remove/add方法或者其他线程并发时修改了集合的内容,就属于fail-fast机制,即是一个错误,但是该错误会尽最大可能地抛出ConcurrentModificationException异常 ...
分类:
其他好文 时间:
2020-06-25 15:41:03
阅读次数:
60
无论你安装过多少次mysql,仍然会出现各种各样的错误,既然出现了,就想办法解决它:OK! 接下来教大家怎样查看错误日志,去解决懵逼的代码错误。 错误: 经过一些列的 重启操作、查看错误详情,并不能精准找到错误原因,经过一番百度,发现有说磁盘空间不足的、有说需要删除var/lib/mysql的 无论 ...
分类:
数据库 时间:
2020-06-25 14:04:10
阅读次数:
329
Qt Release 构建时强制包含调试信息 https://stackoverflow.com/questions/6993061/build-qt-in-release-with-debug-info-mode 在Qt5中,调用时configure,只需添加选项-force-debug-info ...
分类:
其他好文 时间:
2020-06-24 23:39:52
阅读次数:
74
首先呢是http.js文件代码::: const app = getApp(); var http = { get: function(url, data, callback) { data.access_token = wx.getStorageSync('access_token'); wx.r ...
分类:
微信 时间:
2020-06-24 23:34:28
阅读次数:
153
默认的路由日志是这样的: [GIN-debug] POST /foo --> main.main.func1 (3 handlers) [GIN-debug] GET /bar --> main.main.func2 (3 handlers) [GIN-debug] GET /status --> ...
分类:
其他好文 时间:
2020-06-24 23:16:17
阅读次数:
39