View Code of Problem 78

#include <stdio.h>
#include <string.h>
void main(){
	char a[100],b[100],c[100],t[100];
	gets(a);
	gets(b);
	gets(c);
	if(strcmp(a,b)){
		strcpy(t,a);
		strcpy(a,b);
		strcpy(b,t);
	}
	if(strcmp(a,c)){
		strcpy(t,a);
		strcpy(a,c);
		strcpy(c,t);
	}
	if(strcmp(b,c)){
		strcpy(t,b);
		strcpy(b,c);
		strcpy(c,t);
	}
	puts(a);
	puts(b);
	puts(c);
}

Double click to view unformatted code.


Back to problem 78