常用C库函数与WIN32函数比较一览表
Win32 Equivalents for C Run-Time Functions
ID: Q99456
The information in this article applies to:
Microsoft Win32 Application Programming Interface (API), included with:
Microsoft Windows NT, versions 3.1, 3.5, 3.51
Microsoft Windows 95
SUMMARY
Many of the C Run-time functions have direct equivalents in the Win32 application programming interface (API). This article lists the C Run-time functions by category with their Win32 equivalents or the word "none" if no equivalent exists.
MORE INFORMATION
NOTE: the functions that are followed by an asterisk (*) are part of the 16-bit C Run-time only. Functions that are unique to the 32-bit C Run-time are listed separately in the last section. All other functions are common to both C Run-times.
Buffer Manipulation
_memccpy none
memchr none
memcmp none
memcpy CopyMemory
_memicmp none
memmove MoveMemory
memset FillMemory, ZeroMemory
_swab none
Character Classification
相关文档:
开发环境:Ubuntu9.10,python2.6,gcc4.4.11,ubuntu下的python运行包和开发包是分开的,因此需要在新利得里面安装python-all-dev,从而可以在代码中引用python的头文件和库。2.下面是一个最简单的可以供python调用的c扩展模块,假设c程序文件名为foo.c:代码#include <Python.h>
static PyObject* foo_b ......
函数名: abs 功 能: 求整数的绝对值
用 法: int abs(int i);
程序例:
#include <stdio.h>
#include <math.h>
int main(void)
{
int number = -1234;
printf("number: %d absolute value: %d\n", number, abs(number));
return 0;
}
函数名: atof
功 ......
C/C++位操作
一、传统的C方式位操作:
1.基本操作:
使用一个unsigned int变量来作为位容器。
2.操作符:
| 按位或操作符:result=exp1|exp2;当exp1和exp2中对应位中至少有一个为1时,result中对应位为1,否则为0。
& 按位与操作符::result=exp1&exp2;当exp1和exp2中对应位全为1时 ......
用单引号引起的一个字符实际上代表一个整数,整数值对应于改字符在编译器采用的字符集中的序列值。
用双引号引起的字符串,代表的是一个指向无名数组起始字符的指针,该数组被双引号之间的字符以及一个额外的二进制值为零的字符'\0'初始化。
printf("Hello world\n");
与
char hello[] = {'H', 'e', 'l', 'l', 'o', ' ' ......
Eclipse除了可以開發Java之外,還支援了許多語言,現在先介紹
C、C++的開發環境設定,以後有機會再介紹其它的。Enjoy it!
OS:Windows XP Professional SP1
使用版本:Eclipse 2.1.2
一.首先要下載CDT,Eclipse 2.1.2 ......