开发者

Command line arguments or reading file

开发者 https://www.devze.com 2023-03-07 16:00 出处:网络
I need to process 10 values. Which way would be better? Getting them as command line arguments or instead reading from a file?

I need to process 10 values. Which way would be better? Getting them as command line arguments or instead reading from a file? Using C by th开发者_如何学运维e way.


If you make them as command-line arguments, then you could do it both ways... i.e.

 a.out 1 2 hello abc ... 

or

a.out \`cat file_with_arguments.txt\
0

精彩评论

暂无评论...
验证码 换一张
取 消