#include <stdio.h>
#include <stdlib.h>
int main()
{
int q[18]={0,6,3,1,7,5,8,9,2,4},head=1,tail=10;//读入n
while(head<tail)
{
printf("%d ",q[head]);
head++;
q[tail]=q[head];
tail++;
head++;
}
//把数加到末尾
return 0;
}
#include <stdio.h>
#include <stdlib.h>
int main()
{
int q[18]={0,6,3,1,7,5,8,9,2,4},head=1,tail=10;//读入n
while(head<tail)
{
printf("%d ",q[head]);
head++;
q[tail]=q[head];
tail++;
head++;
}
//把数加到末尾
return 0;
}