码迷,mamicode.com
首页 >  
搜索关键字:strlen sizeof    ( 8171个结果
Win32 实现 MFC CFileDialog 对话框
void CWriteWnd::OpenFileDialog(){ OPENFILENAME ofn; TCHAR szFile[MAX_PATH] = _T(""); ZeroMemory(&ofn, sizeof(ofn)); ofn.lStructSize = sizeof(ofn); o.....
分类:Windows程序   时间:2014-07-07 08:31:40    阅读次数:327
理解流方式上传和form表单上传
流方式上传:$post_input = 'php://input';$save_path = dirname( __FILE__ );$postdata = file_get_contents( $post_input );if ( isset( $postdata ) && strlen( $po...
分类:其他好文   时间:2014-07-06 19:08:44    阅读次数:177
c语言笔记————函数以
1.函数是具有特定功能的代码段。通俗地讲,一连串语句组合在一起,实现了某一功能,我们为他们起了一个名字strlen 求字符串?长度函数,?用于求指定字符串的?长度!strcpy 字符串拷?贝函数,?用于实现字符串的赋值函数的使?用可以省去重复代码的编写,?大?大简化程序,提?高开发效率。void 空...
分类:编程语言   时间:2014-07-06 15:54:41    阅读次数:185
C++类所占内存大小计算
C++类所占内存大小计算转载时请注明出处和作者联系方式文章出处:http://blog.csdn.net/chenchong08作者联系方式:vision_chen@yeah.net说明:笔者的操作系统是32位的。class A {};sizeof( A ) = ?sizeof( A ) = 1明明...
分类:编程语言   时间:2014-07-04 00:14:20    阅读次数:355
win32 api
Microsoft在StrSafe.h定义了新的安全字符串函数为了防止缓冲区溢出,在将一个可写缓冲区作为参数传递时,必须传递它的大小,大小可以有_countof获得,_countof获取字符数, sizeof获取字节数for example: int a[10]; // _countof(a) =....
分类:Windows程序   时间:2014-07-03 23:50:47    阅读次数:552
C语言有符号加减溢出
sizeof(short int ) = 2; 测试用例 #include int main() { short int a = -32768; short int b = 0x8000; short int c = 0xffff; short int d = 0x8001; printf("%d, %d, %d, %d\n", a, b, c...
分类:编程语言   时间:2014-07-03 17:15:54    阅读次数:275
网络流模板
在这里我只放我的模板和一些我个人的“理解”。。最大流测试题:usaco草地排水EK:时间复杂度:O(VE^2)代码复杂度:最易代码:#include #include #include using namespace std;#define CLR(a) memset(a, 0, sizeof(a)...
分类:其他好文   时间:2014-07-02 20:54:22    阅读次数:276
将一段含有0的字符数组赋给string
string有个成员函数,assign()可以这样:1 string str;2 str.assign(temp, sizeof(temp));
分类:其他好文   时间:2014-07-02 17:23:54    阅读次数:229
uva 11728 - Alternate Task(数论)
题目链接:uva 11728 - Alternate Task 题目大意:给出S,求N,要求N所有的因子和为S。 解题思路:枚举因子i,所有整除i的数和加上i。 #include #include const int N = 1005; int n, c[N], v[N]; void init () { memset(c, 0, sizeof(c)); ...
分类:其他好文   时间:2014-07-02 16:55:04    阅读次数:167
windows 下获取当前进程的线程数量
#include int get_thread_amount(){ int i = 0; char Buff[9]; PROCESSENTRY32 pe32; pe32.dwSize = sizeof(pe32); int processid = GetCurrentP...
分类:编程语言   时间:2014-07-02 13:50:40    阅读次数:282
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!