This is Ali's latest test, and the following code prints the required string. If you have other questions, you can modify the following code to provide additional functionality.
As you can see from the title, the character growth is 4 times times changed. The first time is four, the second is 16, in turn, 64,128, ..... ....... ......... From above, and with certain regularity.
void Seq_string () {char str[1100][10];//apply for a two-bit character array memset (str, ' I ', sizeof (str)); int i=0,j=0,k=0,t=1,m=0,w,q=0,p=0,f;
T is used to store the length of a series of characters, m stands for rows, and n represents the column char *temp= "ABCD"; for (I=0;i<strlen (temp); i++) {str[m++][k]=temp[i]; First assigns "ABCD" to the Array,} k++; K is used to denote the number of columns, that is, a line with several characters while (1) {j=0;j<=k;j++) {t*=4; The characters in turn increase with the power of 4, and T is used to save the number of strings that need to be added next time} w=t; W is used to temporarily save the value of T f=m; F is used to temporarily save the number of rows at that time, for the (i=0;i<=k;i++) {while (t--)/cycles, the first time is 4, the second is 4*4, and then the multiples of 4 are increased by {if (i==0)///At the first time
Assigned respectively, A,b,c,d {str[m++][i]=temp[q++];
if (q==4) {q=0;
} else {//str[m++][i]=temp[] strcat (Str[m++],str[p]); The number of t/4,p before replication increases by 1 with a string of 4. So, there are the following
if (t%4==0) {p++; }} t=w;
Cycle again, m=f; } m=w+f;
After a loop, M is F plus the number of additions. T=1;
Turn T into 1 and continue to the next cycle if (m>1010) {break;
} for (i=0;i<100;i++) {printf ("%d:%s\n", I,str[i]); }
}