program pil_8_44_ab(input,output);
label 9999;
const
	n = 10;
type
	str = packed array [1..n] of char;
var
	x, y : str;
  i, j, xlen, ylen : integer;
  c : char;
  ag,f : boolean;
begin
	Write('Input x and y (comma bitween them and point after) : ');
	read(c);
  xlen := 0;
  while c<>',' do begin
		xlen := xlen+1;
    x[xlen]:=c;
    read(c);
  end;
	read(c);
  ylen := 0;
  while c<>'.' do begin
		ylen := ylen+1;
    y[ylen]:=c;
    read(c);
  end;

  if xlen<>ylen then begin
  	ag := false;
    goto 9999;
  end;

  for i:=1 to xlen do begin
  	c := x[i];
  	j := 1;
    f := true;
    while (j<=ylen) and f do begin;
    	if y[j]=c then begin
      	y[j] := ',';
				f := false;
      end;
      j := j+1;
    end;
    if f then begin
    	ag := false;
      goto 9999;
    end;
  end;
	ag := true;
9999:
	if ag then WriteLn('true')
  else WriteLn('false');
end.