當(dāng)前位置:高考升學(xué)網(wǎng) > 招聘筆試題 > 正文
a test for the c programming language
i. history
1. c was originally designed for and implemented on the (what) operating system on the dec pdp-11, by (who) .
2. the most recently approved ansi/iso c standard was issued in (when) , and single line comments notation “//” is or isn’t a feature of c89.
ii. syntax and semantics
1. in a runtime c program, auto variables are stored in , static variables are stored in , and function parameters are stored in .
a. stack b. heap c. neither stack nor heap
2. the statement “extern int x;” is a , and the keyword extern is used during .
a. variable declaration b. variable definition
c. compilation time d. runtime
3. there is a complicated declaration: void ( signal (int, void ()(int)) ) (int);
if a statement “typedef void (p) (int);” is given, please rewrite this complicated declaration.
4. the following code is a segment of c program.
..........
void func(int p)
{...........}
..........
main()
{
int num=0;
.........
func(&num);
........
}
..........
here, the function argument “&num” is passed .
a. by value b. by reference
iii. practice
create a tree, which has h (h>0) layers, and its each node has w (w>0) sub-nodes.
please complete the following incomplete solution.
#include
#include
struct tree{
char info;
p_sub; //link to sub-nodes
};
// allocate memory and initiate
void dnode ( struct tree tmp )
{
=malloc( sizeof (struct tree) );
= 0x41;
= null;
}
struct tree dtree (struct tree subtree, int height, int width)
{
int i;
if ( !subtree ) //if necessary, allocte memory for subtree
denode(subtree);
if ( height == 1 )
return subtree;
else if ( height == 2 ) {
struct tree leaf = null;
for ( i=0; i
denode ( );
;
leaf = null;
}
return subtree;
}
else {
for ( i=0; i
}
return subtree;
}
}
main()
{
.........
struct tree root = null;
root = dtree (root, h, w) ; // h and w are integers get from input
.........
}
2020年河北新聞網(wǎng)兩學(xué)一做
時間:2023-09-18 07:0:242020年河北新聞網(wǎng)兩學(xué)一做
時間:2023-09-15 11:0:59兩學(xué)一做學(xué)習(xí)教育知
時間:2023-09-21 06:0:302020年開展兩學(xué)一做學(xué)習(xí)教
時間:2023-09-19 21:0:30
律師事務(wù)所律師筆試題和面試題答案2023-09-18 09:26:26
施奈德筆試題和面試題答案目2023-09-18 11:54:52
陜西國際商貿(mào)學(xué)院在重慶高考專業(yè)招生計劃(人數(shù)+代碼)2025-05-22 10:38:12
安徽建筑大學(xué)和新余學(xué)院哪個好 分數(shù)線排名對比2025-05-22 10:36:54
襄陽職業(yè)技術(shù)學(xué)院廣西錄取分數(shù)線及招生人數(shù) 附-2020最低位次排名2025-05-22 10:35:29
長江大學(xué)和新疆師范大學(xué)哪個好 分數(shù)線排名對比2025-05-22 10:34:16
錦州師范高等?茖W(xué)校在遼寧高考專業(yè)招生計劃(人數(shù)+代碼)2025-05-22 10:32:49
山東高考排名在17550的考生能報什么大學(xué)(原創(chuàng))2025-05-22 10:31:33
廣州華立學(xué)院的英語專業(yè)分數(shù)線(附2020-最低分排名怎么樣)2025-05-22 10:30:14
蘭州石化職業(yè)技術(shù)大學(xué)的理化測試與質(zhì)檢技術(shù)專業(yè)分數(shù)線(附2020-最低分排名怎么樣)2025-05-22 10:29:06
泉州師范學(xué)院和亳州學(xué)院哪個好 分數(shù)線排名對比2025-05-22 10:27:53
貴州醫(yī)科大學(xué)在江西高考專業(yè)招生計劃(人數(shù)+代碼)2025-05-22 10:26:23
東莞城市學(xué)院和西安工商學(xué)院哪個好 分數(shù)線排名對比2025-05-22 10:24:51
山東海事職業(yè)學(xué)院的水路運輸安全管理專業(yè)分數(shù)線(附2020-最低分排名怎么樣)2025-05-22 10:23:44 


