实现计算二分图最大匹配的匈牙利算法,用的是C++\C语言
2023-12-17 08:05:21 15KB 匈牙利算法
1
CKY 算法实现,使用c++语言实现,将rule_cky.txt文件放到与cky.exe相同的目录下就可以使用
2023-12-16 08:01:52 146KB
1
用C++实现MD5算法,定义了一个MD5类,用户可以直接调用方法生成字符串的md5校验值
2023-12-16 08:00:59 3KB MD5
1
floyd算法的C++代码,用的时候只要改几个参数就可以了
2023-12-15 08:00:56 918B 代码
1
C++部分使用了Wei Dai整理的开源C++加密工具cryptopp(www.cryptopp.com),cryptopp是一个非常优秀和完善的开源C++加密工具,将C++技术和设计模式使用到了淋漓尽致的地步,不过对于初学者来说比较难以上手,特别是需要将项目交给初学者来实现的时候,所以当时在cryptopp的基础上做了一些封装,并且将RSA,AES,SHA1,RSA-SHA1 Sign分离成独立的类,并且添加了Base16和Base64编码算法,使用这几个加密算法,几乎可以解决一般项目对通信安全的需要。 Java部分使用了JDK自带的SunJCE加密框架,一般网上可以找到的Java加密解密都是使用SunJCE框架,还有一个比较著名的 Java开源加密工具是bouncycastle(http://www.bouncycastle.org/),因为SunJCE是JDK自带的,所以使用比较方便,相对于cryptopp,SunJCE要容易上手得多,几乎不需要再做封装,不过为了跟C++封装统一,也做了简单的封装,保持C++接口和Java接口相近。 C++封装在Visual Studio 2003下测试通过,Java封装在jdk1.5.0_14下测试通过。 更详细的信息,解压缩后参考/doc/crypto.doc和源代码.
2023-12-15 07:05:14 225KB RSA AES SHA1 RSA-SHA1
1
八数码问题 A星算法 C#描述 visual studio 2008
2023-12-11 05:01:25 401KB 八数码问题 A星算法 C#描述
1
C++ 实现DCT算C + + realize DCT algorithm
2023-12-10 08:03:33 78KB
1
MD5 算法是用来进行数字签名和算法。能将任意长的字符串生产128位长的等长字符。
2023-12-10 08:03:15 4KB MD5
1
这是徐士良的常用算法程序集(C++语言描述)第四版源码,采用面向对象实现。
2023-12-09 08:04:57 200KB
1
看到一个不错的c++实现的md5算法 class MD5 { public: typedef unsigned int size_type; // must be 32bit MD5(); MD5(const std::string& text); void update(const unsigned char *buf, size_type length); void update(const char *buf, size_type length); MD5& finalize(); std::string hexdigest() const; friend std::ostream& operator<<(std::ostream&, MD5 md5); private: void init(); typedef unsigned char uint1; // 8bit typedef unsigned int uint4; // 32bit enum {blocksize = 64}; // VC6 won't eat a const static int here void transform(const uint1 block[blocksize]); static void decode(uint4 output[], const uint1 input[], size_type len); static void encode(uint1 output[], const uint4 input[], size_type len); bool finalized; uint1 buffer[blocksize]; // bytes that didn't fit in last 64 byte chunk uint4 count[2]; // 64bit counter for number of bits (lo, hi) uint4 state[4]; // digest so far uint1 digest[16]; // the result // low level logic operations static inline uint4 F(uint4 x, uint4 y, uint4 z); static inline uint4 G(uint4 x, uint4 y, uint4 z); static inline uint4 H(uint4 x, uint4 y, uint4 z); static inline uint4 I(uint4 x, uint4 y, uint4 z); static inline uint4 rotate_left(uint4 x, int n); static inline void FF(uint4 &a, uint4 b, uint4 c, uint4 d, uint4 x, uint4 s, uint4 ac); static inline void GG(uint4 &a, uint4 b, uint4 c, uint4 d, uint4 x, uint4 s, uint4 ac); static inline void HH(uint4 &a, uint4 b, uint4 c, uint4 d, uint4 x, uint4 s, uint4 ac); static inline void II(uint4 &a, uint4 b, uint4 c, uint4 d, uint4 x, uint4 s, uint4 ac); }; std::string md5(const std::string &str);
2023-12-06 08:01:50 5KB md5
1