#include <stdio.h>
int main()
{int i,j,upp,low,temp;
char text[8][3];
upp=low=0;
for(i=0;i<8;i++)
{printf("please input line %d: \n",i+1);
gets(text[i]);
for(j=0;j<8&&text[i][j]!='\0';j++);
{if(text[i][j]>='A'&& text[i][j]<='Z')
 upp++;
 else if(text[i][j]>='a' && text[i][j]<='z')
	low++;
    
  if(text[i][j]>text[i][j+1])
 {temp=text[i][j+1];
 text[i][j+1]=text[i][j];
 text[i][j]=temp;
 }

}
}
printf("\nupper case :%d\n",upp);
printf("\nlower case :%d\n",low);
printf("The changed array is: \n");
for(i=0;i<8;i++)
 for(i=0;i<8;i++)
 printf("%d",text[i][j]);

}