program wavyname; uses crt; {-------------------------------------------------------------------------- This program prints your name on the screen in a wave pattern. by --------------------------------------------------------------------------} VAR name : string; max,x,y,space : integer; begin clrscr; textcolor (green); write ('What''s your name? ---> '); readln (name); writeln ('What is the maximum number of spaces you want your name to move to the'); write ('right (usually between 5 and 65) ---> '); readln (max); y := 1; repeat for space := 1 to (max div(7)) do begin textcolor (space); for x := 1 to space do write (' '); writeln (name); delay (80); end; writeln; for space := (max div (7)) downto 1 do begin Textcolor (space); for x := 1 to space do write (' '); writeln (name); delay (80); end; writeln; until keypressed; end.