Author Topic: file input to C programs  (Read 5158 times)

moey

  • Guest
file input to C programs
« on: April 22, 2011, 08:42:38 am »
Hey guys,
So, i was wondering if there was a way to make your program read a file as standard input.
In linux the command was ./run < input.txt, with ./run being the program and input.txt being the file which includes the data.
thanks

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: file input to C programs
« Reply #1 on: April 22, 2011, 09:52:10 am »
Search the forum, it is answered million times, when you found an answer, please enrich our FAQ in the wiki -> http://wiki.codeblocks.org/index.php?title=FAQ
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]