program abc;
uses wincrt;
var
name : string[10];
tel : string[8];
a : text;
begin
assign(a, 'C:\tel.txt');
reset(a);
repeat
write('Enter name of student (* to end): ');
readln(name);
if (name <> '*')
then begin
name := name + ' ';
write('Enter telephone number: ');
readln(tel);
tel := tel + ' ';
writeln(a, name, tel)
end
until name = '*';
close(a)
end.