system("command > /path/to/result.txt");