{
#! /bin/bash
echo === 1 ===
echo 'TEST' > test.txt
./rwr0
cat test.txt
echo === 2 ===
./rwr0 "anything"
cat test.txt
echo === 3 ===
rm test.txt
exit 0
}
program rwr0;
uses mtx09;
var
  a: mtx;
begin
  rwr('test.txt');
  equ(a,'1 2 3; 4 5 6');
  mwr(a,'test.txt');
  add(a,10.0);
  if paramcount>0 then rwr('test.txt');
  mwr(a,'test.txt');
end.
