Home > database >  The magician licensing, bosses look at code have what problem
The magician licensing, bosses look at code have what problem

Time:01-14

#include
#include
Typedef struct Lnode
{
The int data;
Struct Lnode * next;
} * sqlist;
Sqlist creatlist (sqlist L)
{
Sqlist a, b;
int i;
A=L;
for(i=0; i<=12; I++)
{
B=(sqlist) malloc (sizeof (sqlist));
B - & gt; data=https://bbs.csdn.net/topics/0;
A - & gt; Next=b;
A=b;
}
A - & gt; Next=L - & gt; Next;
A=L - & gt; Next;
Free (L);

Return a;
}
Sqlist operation (sqlist L)
{
Int I=1, j=2;
Sqlist head;
The head=L;
L-> data=https://bbs.csdn.net/topics/1;
While (j<=13)
{
for(i=1; i<=j; I++)
{
L=L - & gt; Next;
If (L - & gt; The data!=0)
{
- I;
}
}
L-> data=https://bbs.csdn.net/topics/j;
+ + j;
}
return head;
}
Void the output (sqlist L)
{
int i;
for(i=1; i<=13; I++)
{
Printf (" the first card for % d % d ", I, L - & gt; The data);
L=L - & gt; Next;
}
}
Int main ()
{
Sqlist L;
L=(sqlist) malloc (sizeof (sqlist));
Creatlist (L);
Operation (L);
The output (L);
return 0;
}
  • Related