perm filename STRIP.SAI[UOR,AIL] blob sn#248618 filedate 1976-11-21 generic text, type T, neo UTF8
00100	
00200	begin "striplf"
00300	    integer chanin,chanout,dummy,eof,flag;
00400	    string namein,nameout;
00500	    integer tchar;
00600	
00700	    print("type in name of input file  ");
00800	    namein ← inchwl;
00900	    print("type in name of output file ");
00950	   nameout←inchwl;
01000	    open(chanin←getchan,"dsk",0,5,0,dummy,dummy,eof);
01100	    lookup(chanin,namein,flag);
01200	    if flag or eof then
01300	       begin
01400	          print("abort");
01500	          call(0,"exit");
01600	       end;
01700	    open(chanout←getchan,"dsk",0,0,5,dummy,dummy,dummy);
01800	    enter(chanout,nameout,flag);
01900	    
02000	    while true do
02100	    begin
02200	       tchar ← wordin(chanin);
02300	       if eof then done;
02400	       if tchar = 0 then
02500	          continue;
02600	       if tchar = '12 then
02700	          continue;
02800	       if tchar = '15 then
02900	          begin
03000	             wordout(chanout,'15);
03100	             wordout(chanout,'12);
03200	          end
03300	       else
03400	          wordout(chanout,tchar);
03500	    end;
03600	    print('15&'12,"successful striping");
03650	    close(chanout);
03700	end "striplf"