bzero
原型:extern void bzero(void *s, int n);
用法:#include <string.h>
功能:置字節字符串s的前n個字節爲零。
說明:bzero無返回值。
舉例:
// bzero.c
#include <syslib.h>
#include <string.h>
main()
{
struct
{
int a;
char s[5];
float f;
} tt;
char s[20];
bzero(&tt,sizeof(tt)); // struct initialization to zero
bzero(s,20);
clrscr();
printf("Initail Success");
getchar();
return 0;
}
bzero
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章
數據結構筆記淺記(三)空間複雜度
原創
2024-03-23 00:43:15
go學習-struct
coder_cll
2020-07-08 12:24:18
杭電hdu 1086 You can Solve a Geometry Problem too 線段相交
wchyumo2009
2020-07-08 12:20:38
ip轉換爲數值 數值轉換爲ip c++
hityct1
2020-07-08 09:03:05
鏈表的建立插入與刪除
陆家三少
2020-07-08 08:35:09
從面向結構到面向對象-----josephus問題(方法二:結構的應用)
yingcongxiao
2020-07-08 05:47:57
線性表的構造
yingcongxiao
2020-07-08 05:47:46
16-棧的幾種用法_案例代碼
ibbo
2020-07-08 05:44:47
[CSS]CSS浮動塌陷及解決辦法
一. CSS浮動 先看一個例子 <html !DOCTYPE> <head> <title>HTML2</title> <style> .div-outer {
osc_oj4rjab5
2024-05-13 23:37:32
SQL 語法快速入門
雄牛
2020-07-08 12:18:30
C語言的一些細節總結
redarm
2020-07-08 10:59:37