Guest User

Untitled

a guest
Oct 16th, 2019
77
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. var
  2.   s : string;
  3.   i : integer;
  4. begin
  5.     readln(s);
  6.     i := 1;
  7.     while i < length(s) do
  8.     begin
  9.         if(s[i] >= '0') and (s[i] <= '9') and (s[i + 1] = ' ')then
  10.         begin
  11.           insert('+', s, i + 1);
  12.           i := i + 1;
  13.         end;
  14.         i := i + 1;
  15.     end;
  16.     writeln(s);
  17. end.
RAW Paste Data