uses crt;
var s:string[150];f:text;
procedure khoitao;
begin
assign(f,'daytang.inp');
{$I-} reset(f); {$I+}
if ioresult>0 then
begin
rewrite(f);reset(f);
end;
readln(f,s);close(f);
assign(f,'Daytang.out');rewrite(f);
end;
function kt(x1,x2:string):boolean;
var e:integer;a,b:longint;
begin
val(x1,a,e);val(x2,b,e);
if a < b then kt:=true
else kt:=false
end;
procedure xuly;
var s2,s3:string[50];s1:string;i,j,e:integer;a,b:longint; dung:boolean;
begin
khoitao;
s1:='';i:=1;
if (s[1]='0') then
while (s[i]='0') and (i<=length(s)) do inc(i);
if (i>length(s)) or ((i<=length(s)) and (kt(copy(s,1,i-1),copy(s,i,length(s)-i+1))=false)) then
writeln(f,s)
else
begin
if i>=2 then
s1:=copy(s,1,i-1)
else s1:=s[1];if i=1 then inc(i);
dung:=false;val(s1,a,e);s3:=s[i];val(s3,b,e);j:=i;
while dung=false do
begin
while (a>=b) and (i<=length(s)) do
begin
s3:=copy(s,j,i-j+1);val(s3,b,e);inc(i);
end;
if (i<length(s)) and (kt(copy(s,j,i-j+1),copy(s,i,length(s)))=true) then
begin
s1:=s1+' '+s3;
s2:=s3;val(s2,a,e);inc(i);s3:=s[i];val(s3,b,e);
j:=i;inc(i);
end
else {if (i<length(s)) and (kt(copy(s,j,i),copy(s,i+1,length(s))=false) then}
begin
s1:=s1+' '+copy(s,j,length(s)) ;
dung:=true;
writeln(f,s1);
end;
end;
end;
close(f);
end;
begin
xuly;
end.