当前位置: 答题翼 > 问答 > 计算机类考试 > 正文
目录: 标题| 题干| 答案| 搜索| 相关
问题

若有以下定义struct link{int data;struct link *next;}a b c *p *q;且变量a和b之间已有如下图所


若有以下定义 struct link { int data; struct link *next; } a,b,c,*p,*q; 且变量a和b之间已有如下图所示的链表结构: 指针p指向变量a,q指向变量c。则能够把c插入到a和b之间并形成新的链表的语句组是

A、a.next=C;c.next=b;

B、p.next=q;q.next=p.next;

C、p->next=&c;q->next=p->next;

D、(*p).next=q;(*q).next=&b;

参考答案
您可能感兴趣的试题
  • (36 ) 设有定义 :struct complex{ int real,unreal; } data1={1,8},data2;则以下赋值语句中错误

  • (36 ) 设有定义 :struct complex{ int real,unreal; } data1={1,8},data2;则以下赋值语句中错误

  • 有以下程序#include <stdio.h>struct st{int x, y, z;} data[2]={3,10,2,20,15,7};main(){

  • 若有以下定义和语句 struct a{ int n,m;}; struct a st[3]={{2,3},{4,5},{6,7}}; struct a*p=st;

  • 若有以下定义的语句 struct student { int age; int num; }; struct student stu[3]={{1001 20}

  • 若有以下程序段:struct st{int n;int*m:};int a=2 b=3 c=5;struct st s[3]=({101 &a} {102 &