output file as parameter
output file as parameter
minor formating
result is stored in String variable