Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!iuvax!rutgers!bpa!cbmvax!vu-vlsi!lehi3b15!lafcol!pilgrimk From: pilgrimk@lafcol.UUCP (Kenwyn A. Pilgrim) Newsgroups: comp.lang.pascal Subject: Re ***3 posting of function What(where: string): string Keywords: What are these? Message-ID: <454@lafcol.UUCP> Date: 16 Mar 89 17:33:14 GMT Organization: Academic Computer Center, Lafayette College Lines: 40 Direct mail may have been messed up, so I posting to the net. Too bad. {Here's my $0.02} {-------------------------------------------------} uses Crt; var a: string; function what(var where: string): string; begin what := where; writeln('Hit Esc...'); repeat until ReadKey=#27; delete(String(Ptr(Seg(What),Ofs(What))^),5,10); end; begin a := 'Help me please'; writeln(what(a)) end. {-------------------------------------------------} { Some notes: When run as is (TP40 compiler) 'Help me please' is the result. The variable 'a' remains unchanged. If the 'uses Crt' line is removed along with writeln('Hit Esc...'); repeat until ReadKey=#27; the computer is hung. (Haven't figured this out as yet); Maybe this helps, Maybe it doesn't, but what do you expect for $0.02 ???? When you do get a correct sol'n, please post to the net. This is more interesting than I originally thought! -Kenwyn }