Which node type will use only NetBIOS broadcast requests using UDP broadcast?()
A: b-node (type 0x01)
B: p-node (type 0x02)
C: m-node (type 0x04)
D: h-node (type 0x08)
A: b-node (type 0x01)
B: p-node (type 0x02)
C: m-node (type 0x04)
D: h-node (type 0x08)
举一反三
- 已知不带头结点的单链表L,下面用函数实现的在第一个元素前面插入值为x的元素结点的算法错误的是( ) A: void insert(List *L,elemtype x){ node d=new node(x); d.next=*L; *L=&d;} B: List * insert(List *L,elemtype x){ node d=new node(x); d.next=*L; *L=&d; return L;} C: void insert(List *L,elemtype x){ ptr p=*L; node d=new node(x); ptr q=&d; p->next=q; L=&q;} D: List insert(List *L,elemtype x){ node d=new node(x); d.next=*L; return &d;}
- 已知不带头结点的单链表L,下面用函数实现的在第一个元素前面插入值为x的元素结点的算法错误的是( ) A: void insert(List *L,elemtype x){ ptr p=*L; node d=new node(x); ptr q=&d; q->next=p; L=&q;} B: List * insert(List *L,elemtype x){ ptr p=*L; node d=new node(x); ptr q=&d; q->next=p; L=&q; return L;} C: void insert(List *L,elemtype x){ ptr p=*L; node d=new node(x); ptr q=&d; p->next=q; L=&q;} D: List * insert(List *L,elemtype x){ ptr p=*L; node d=new node(x); ptr q=&d; q->next=p; return &q;}
- 已知不带头结点的单链表L,下面用函数实现的在第一个元素前面插入值为x的元素结点的算法错误的是( ) A: void insert(List *L,elemtype x){ ptr p=*L; node d=new node(x); ptr q=&d; q->next=p; L=&q;} B: List * insert(List *L,elemtype x){ ptr p=*L; node d=new node(x); ptr q=&d; q->next=p; L=&q; return L;} C: void insert(List *L,elemtype x){ ptr p=*L; node d=new node(x); ptr q=&d; p->next=q; L=&q;} D: List * insert(List *L,elemtype x){ ptr p=*L; node d=new node(x); ptr q=&d; q->next=p; return &q;}
- 中国大学MOOC: 下面程序执行后的输出结果是:#include <iostream>#include <cmath>using namespace std;struct NODE {int num; struct NODE *next;};int main(){struct NODE *p,*q,*r;p=new NODE;q=new NODE;r=new NODE;p->num=10; q->num=20; r->num=30;p->next=q;q->next=r;cout<<p->num+q->next->num<<endl; return 0;}
- 设有以下定义: struct node { int data; struct node *next; }*p; 则以下的语句中正确的是()。 A: p=malloc(sizeof(struct node)) B: p=(struct node *)malloc(sizeof(struct node)) C: *p=(struct node *)malloc(4) D: p=(struct node )malloc(sizeof(struct node))