I recently wrote this code to execute system command in C. I just want to measure time performed by this system command.
However, I don't want the output results to be displayed upon executing this program.
#include <stdio.h>
int main(int argc, char* argv[])
{
system("ls");
return 0;
}
How do I discard the output from the system command?