I have a program that is supposed to write output to a .txt file does it work with gdb?

+3 votes
asked Mar 18, 2018 by Fabian
so my program is set to write output to both"example.txt" and standard output. i created another file in the online compiler called "example.txt" but the compiler doesnt write to it.

is this something that can only be done in a local compiler or do i have to do something else to either :

 get it to write to a file in the online compiler,

get it to write to a file on my computer

1 Answer

0 votes
answered Mar 19, 2018 by Shane Such (840 points)
i tried it out  with c++ and it worked but i don't know where the file is that i wrote to so yes and no
asked Jun 21, 2018 by Kristi Hansen (120 points) Where is a file I create with fstream located on my local hard drive?
commented Aug 18, 2018 by Ethan Alexander Lee (580 points)
I'd just download either Code::Blocks or Visual Studio.
http://www.codeblocks.org/                        - Basic C/C++ environment with project capability.
https://visualstudio.microsoft.com/          - Larger but more advanced environment with the
                                                                                  ability to program in several languages and add-ons.
Welcome to OnlineGDB Q&A, where you can ask questions related to programming and OnlineGDB IDE and and receive answers from other members of the community.
...