知識社群登入
[程式練功區]C程式-Homework3
by 艾鍗學院, 2012-03-30 18:34, 人氣(1934)

1) 寫一個show_bitmap函式可將二維陣列的值輸出,輸出方式:當bit為1時輸出’*’,0輸出空白
字元’  ’,每處理完2個byte輸出換行'\n' 

void show_bitmap(int (*a)[30],int row);

char array[2][30]=
{0x8,0x20,0x8,0x24,0xfe,0xfe,0x8,0x20,
 0x0,0x0,0x8,0x20,0x4,0x40,0x4,0x40,
 0x2,0x80,0x1,0x0,0x2,0x80,0xc,0x70,
 0x30,0xe,0xc0,0x4,0x0,0x0
},
{
0x20,0x20,0x51,0xfc,0x88,0x88,0x0,0x50,
0xfb,0xfe,0x22,0x22,0x22,0x22,0xf9,0xfc,
0x21,0x24,0x21,0x24,0xa9,0x24,0x71,0x2c,
0x20,0x20,0xf8,0x20,0x0,0x0
}
};


附件