program kadai21(input , output , opfile); type Kojindate = record name : packed array [1..10] of char; tel : packed array [1..15] of char; end; var opfile : file of Kojindate; a : Kojindate; begin repeat rewrite( opfile , 'intdate' ); writeln('名前:'); readln( a.name ); writeln('電話番号'); readln( a.tel); write(opfile , a); until a.name = 'end'; reset ( opfile , 'intdate' ); while not eof(opfile) do begin repeat read( opfile , a ); writeln( '名前:',a.name , '電話番号:' , a.tel); until a.name = 'end' end end.