08 2022 档案
摘要:网上看了一圈,看到几个都是用数组实现的 我用树结构重写了一遍 #ifndef SEGMENTTREE_H #define SEGMENTTREE_H #include <vector> template<typename T> class SegmentTree { public: SegmentT
阅读全文
摘要:Python C API:提供了一种利用C++编写Python模块的方式 Python pybind11库:提供了一种将现有C++函数封装为接口以供Python调用的方式 https://zhuanlan.zhihu.com/p/345158763
阅读全文
摘要:pair<int, int> generate() { return {1, 2}; } auto [a, b] = generate(); // a=1, b=2 在刷算法题时遇到这种写法,这种语法称为 “结构化绑定声明”(Structured binding declaration) 右值可以是
阅读全文
摘要:Basing Cryptography on Intractable Computation read The Joy of Cryptography 如何定义一个安全的加密算法? 我们经常讨论如何进行加密,如何设计算法来从理论上保证“不可破解”。但是从实践上来说,假如对方能够以无限的算力来猜测,那
阅读全文
摘要:Secret Sharing Scheme read from The Joy of Cryptography 定义:一个TSSS (t out-of n threshold secret-sharing scheme)包含了以下的一些操作: Share(拆分):随机性的,其需要能够将一条Messa
阅读全文

浙公网安备 33010602011771号