
(*********************************************************************

        Adapted from
        Roman E. Maeder: Programming in Mathematica,
        Second Edition, Addison-Wesley, 1991.

 *********************************************************************)


MyReadList[fileName_String, thing_:Expression] :=
	Module[{file, expr, list = {}},
		file = OpenRead[fileName];
		If[ file === $Failed, Return[list] ];
		While[ True,
			expr = Read[file, thing];
			If[ expr === EndOfFile, Break[] ];
			AppendTo[list, expr]
		];
		Close[file];
		list
	]
