#include<stdio.h>
#include<stdlib.h>
#include<string.h>
void main()
{
char a[80]={'\0'},b[80]={'\0'},c[80]={'\0'},*p=a,*q=b,*w=c,*t=NULL;
printf("input 3 string:");
gets(p); gets(q); gets(w);
printf("3 string:");
puts(p); puts(q); puts(w);
t=p;
if(strcmp(t,q)<0)
t=q;
if(strcmp(t,w)<0)
t=w;
printf("Maximun:");
puts(t);
system("pause");
}
(C)在三个字符串中找最大的字符串
最新推荐文章于 2023-03-18 15:23:07 发布