岚天逸见

上一页 1 ··· 3 4 5 6 7 8 9 10 11 ··· 78 下一页

2023年11月22日 #

Go使用开源库go-excelize操作Excel文件

摘要: 以下是一个示例代码,读取一个 Excel 文件并打印其中的所有单元格值: package main import ( "fmt" "github.com/30x/go-excelize" ) func main() { // 打开 Excel 文件 f, err := excelize.OpenFi 阅读全文

posted @ 2023-11-22 14:32 岚天逸见 阅读(260) 评论(0) 推荐(0)

2023年11月10日 #

APISIX源码安装问题解决

摘要: 官网手册的安装语句: curl https://raw.githubusercontent.com/apache/apisix/master/utils/install-dependencies.sh -sL | bash - 执行 install-dependencies.sh 报如下错误: Tr 阅读全文

posted @ 2023-11-10 19:42 岚天逸见 阅读(422) 评论(0) 推荐(0)

2023年9月15日 #

基于python+selenium的自动批量添加

摘要: 场景 点击添加”新增“按钮,弹出”新增对话框“,输入各种数据,然后点击”确定“按钮,如此循环。数量多,这样操作累人。 selenium Selenium 是一个用于自动化 Web 浏览器操作的库,可以实现模拟点击、输入文本等操作。 代码实现 #!/usr/bin/env python3 # -*- 阅读全文

posted @ 2023-09-15 16:05 岚天逸见 阅读(169) 评论(0) 推荐(0)

2023年9月5日 #

取得std::ifstream对象的文件描述符

摘要: 使用C++标准库无法取得std::ifstream对象的文件描述符,但GNU libstdc++库可以取得: #include <fstream> #include <iostream> #include <ext/stdio_filebuf.h> int main() { std::ifstrea 阅读全文

posted @ 2023-09-05 14:18 岚天逸见 阅读(84) 评论(0) 推荐(0)

2023年8月30日 #

利用CONVERT和CAST解决MySQL查询的乱码问题

摘要: 有如下一张表 : ```sql CREATE TABLE t_test_table (f_f1 varchar(16)) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb3; ``` 往表 t_test_table 的 f_f1 字段写入的为 阅读全文

posted @ 2023-08-30 17:14 岚天逸见 阅读(111) 评论(0) 推荐(0)

2023年8月28日 #

chatGPT的js信号量实现

摘要: ### 信号量类 在 JavaScript 中,可以使用 Promise 和 async/await 来模拟信号量,下面是一个简单的信号量实现: ```js class Semaphore { constructor(maxConcurrency) { this.maxConcurrency = m 阅读全文

posted @ 2023-08-28 18:20 岚天逸见 阅读(59) 评论(0) 推荐(0)

2023年8月25日 #

Linux CPU 使用率统计

摘要: CPU 使用率统计脚本: ```bash for ((i=0;i<10000;++i)) do top -n 1|awk -F'[,| ]+' /'%Cpu'/'{ printf("%s %.01f\n",strftime("[%Y-%m-%d %H:%M:%S]",systime()),100-$ 阅读全文

posted @ 2023-08-25 15:00 岚天逸见 阅读(40) 评论(0) 推荐(0)

2023年8月15日 #

chatGPT用C++写的HMAC-SHA256函数

摘要: 以下内容全为 chatGPT 生成: ```cpp #include #include #include #include std::string hmac_sha256(const std::string &key, const std::string &data) { unsigned char 阅读全文

posted @ 2023-08-15 15:58 岚天逸见 阅读(380) 评论(0) 推荐(0)

2023年7月27日 #

C++不同标准兼容性问题集

摘要: * **特化模板兼容性** 下列代码在 c++17 及之前都是可以的,但从 c++20 开始编译报语法错误: ```cpp // g++ -g -std=c++20 -o x x.cpp;./x #include #include template struct X { X(type t) { th 阅读全文

posted @ 2023-07-27 09:42 岚天逸见 阅读(103) 评论(0) 推荐(0)

2023年7月25日 #

使用gcc-13.1.0编译安装thrift-0.18.1

摘要: 执行 configure 生成 Makefile,排除掉不需要的语言支持和测试等: ```bash ./configure --prefix=/usr/local/thrift-0.18.1 --with-boost=/usr/local/boost --with-libevent=/usr/loc 阅读全文

posted @ 2023-07-25 17:07 岚天逸见 阅读(101) 评论(0) 推荐(0)

上一页 1 ··· 3 4 5 6 7 8 9 10 11 ··· 78 下一页

导航