Home > Back-end >  What's the problem, and big help!
What's the problem, and big help!

Time:05-12

#include
The char Min (char 'arry [], int n);
Void Mypoint (char 'arry [], int n);
Int main ()
{
int n;
Char [] a={' b '};
The char min;
Printf (" please input your character number: ");
The scanf (" % d ", & amp; N);
Mypoint (a, n);
Min=min (a, n);
Printf (" the smallest number is: % c \ n ", min);
return 0;

}


The char Min (char 'arry [], int n)
{
int i;
The char min='arry [0].
for(i=1; I{
If (' arry [I] Min='arry [I];
}
Return min;
}
Void Mypoint (char 'arry [], int n)
{
int i;
Printf (" please enter the % d characters: ", n);
for(i=0; I{
Getchar ();
The scanf (" % c ", & amp; 'arry [I]);

}


}

CodePudding user response:

Reference:
 # include 

The char Min (char 'arry [], int n);
Void Mypoint (char 'arry [], int n);
Int main ()
{
int n;
Char a, [256]={0}.//char [] a={' b '};
The char min;
Printf (" please input your character number: ");
The scanf (" % d ", & amp; N);
Mypoint (a, n);
Min=min (a, n);
Printf (" ASCII value is the smallest character is: the % c \ n ", min);//(" the smallest number is: % c \ n ", min);

return 0;
}


The char Min (char 'arry [], int n)
{
int i;
The char min='arry [0].
for(i=1; I{
If (' arry [I] Min='arry [I];
}
Return min;
}
Void Mypoint (char 'arry [], int n)
{
int i;
Printf (" please enter the % d characters: ", n);
for(i=0; I{
Getchar ();
The scanf (" % c ", & amp; 'arry [I]);
}
}
  • Related