#include <stdio.h>
int main(){
char en[7];
while(scanf("%s",en)!=EOF){;
for(int i=0;i<6;i++){
printf("%d",abs(en[i]-en[i+1]));
}
printf("\n");
return 0;