#!/bin/bash while IFS= read -r line; do factor $line >> $2 done < $1