# include <stdio.h>

int fuzzyStrcmp(char s[], char t[]){
	int i;
	for (i = 0; s[i] != '\0'; i++) {
        if ('a' <= s[i] && s[i] <= 'z') {
            s[i] = s[i] - 32; 
        }
	}
    int k;
   	for (k = 0; t[k] != '\0'; k++) {
        if ('a' <= t[k] && t[k] <= 'z') {
            t[k] = t[k] - 32; 
        }
   	}    
	int h;
	for(h=0;s[h]==t[h];h++){
		if(s[h]=='\0')return 1;
		
	}
	return 0;

}

//メイン関数は書き換えなくてできます 
int main(){
    int ans;
    char s[100];
    char t[100];
    scanf("%s %s",s,t);
    printf("%s  %s -> ",s,t);
    ans = fuzzyStrcmp(s,t);
    printf("%d\n",ans);
    return 0;
}
