Update rand and dsa algorithm test programs so they can support command line filenames and no longer require redirection, which some platforms don't support.