*****
***
*
***
*****
19 *
*****
***
*
***
*****
2
#include
int main()
{
int n, i, j, S=3, V, k, c=1, H=1, N;
char a;
scanf("%d ", &n);
N=n;
scanf("%c", &a);
n = (n-1)/2;
for( i=1; S<=n; i++ )
S = i*(i+2);
S = ----i;
V = 2*i+1;
if( N>=7 )
{
for( i=S; i>-1; i-- ){
if( i0; i-- ){
if(i<=S){ for( k=c; k>0; k--) printf(" "); c--; }
for( j=0; j1 ) printf("\n");
}
}
else
printf("%c", a);
printf("\n%d", N-H);
return 0;
}
____________________________________________________________________________________________
4
320124198808240056
12010X198901011234
110108196711301866
37070419881216001X
12010X198901011234
110108196711301866
37070419881216001X
2
320124198808240056
110108196711301862
All passed
#include
#include
struct ID{
char number[19];
};
int main()
{
int i, n, j, m=0, Sum[100], flag[100], mark[100];
int weight[17]={7, 9, 10, 5, 8, 4, 2, 1, 6, 3, 7, 9, 10, 5, 8, 4, 2};
scanf("%d", &n);
if( n<=0||n>100 ) exit(0);
char CH, num[n];
struct ID IDCheck[n];
for( i=0; i='0'&&IDCheck[i].number[j]<='9' )
Sum[i] += (IDCheck[i].number[j]-'0')*weight[j];
else mark[i] = false; //在前17位数中就出现了'X'直接标记错误
for( i=0; i
_____________________________________________________________________________________________
pcTclnGloRgLrtLhgljkLhGFauPewSKgt
GPLTGPLTGLTGLGLL
#include
#include
int main()
{ int i, n, G=0, P=0, L=0, T=0;
char op[10000];
scanf("%s", op);
n = strlen(op);
for( i=0; i
______________________________________________________________________________________________
10
3 2 22 10 58 8 125
5 1 345 3 211 5 233 7 13 8 101
1 7 8800
2 1 1000 2 1000
2 4 250 10 320
6 5 11 9 22 8 33 7 44 10 55 4 2
1 3 8800
2 1 23 2 123
1 8 250
4 2 121 4 516 7 112 9 10
1 11.63
2 3.63
8 3.63
3 2.11
7 1.69
6 -1.67
9 -2.18
10 -3.26
5 -3.26
4 -12.32
#include
int Swap(int *a, int *b) //交换位置函数
{
int t=*a; *a=*b; *b= t;
}
int main()
{
int i, j, n, m, T1, T2, P, k;
scanf("%d", &n);
int recSum[n], Sum=0, Num[n], Quantity[n];
for(i=1; i<=n; i++)
recSum[i] = Quantity[i] = 0;
for( i=1; i<=n; i++ )
{
scanf("%d", &m);
Num[i] = i;
for( j=0 ; jQuantity[j]&&!k )
{
i++;
k=1;
}
if( recSum[i]==recSum[j]&&Num[i]
————————————————————————————————————————————————————