岚天逸见

随笔分类 -  chatGPT

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

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

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 岚天逸见 阅读(276) 评论(0) 推荐(0) 编辑

导航

统计信息

点击右上角即可分享
微信分享提示