-1

I am a beginner at programming, so this might be a dumb question, but here it is...

I've been going through books, learning languages such as C and C++, and I have a basic understanding of the code. Yet, is this type of code used in actual programs? For example, I open a program on my computer, and there is a nice looking user interface on it. When I code programs at home, my user interface is the command line. But when I go to code a program with a GUI, the code I learn in books doesn't even apply to the GUI code.

So I guess I'm wondering - How does the code and things you learn in books apply to actual programs with a user interface? And is the code used for console applications even used anymore?

Any guidance or help would be appreciated!

Thanks Ian Vaughn

5
  • Yes, it is used in actual programs. Lots (actually, most) of stuff doesn't have GUI and goes behind the scenes. GUI with C++ - just google it, same language, same ideas, just different libraries for this. I.e., I never wrote any GUI in C++ and use console only. Like many people over here. Commented Jun 27, 2013 at 23:58
  • There are numerous books about GUI programming in C and C++. Commented Jun 27, 2013 at 23:59
  • 2
    Although this will probably be closed for other reasons, it's pretty much a dup of stackoverflow.com/questions/875686/advice-for-c-gui-programming Commented Jun 28, 2013 at 0:00
  • The language is universal and building block of everything, you can use it to build GUI library. what you probably mean is that wether function call such as cin/cout can be used for GUI programming, the answer is no, they are just function that tell the operating system to print characters in console, which is also written in C/C++. Commented Jun 28, 2013 at 0:21
  • "is the code used for console applications even used anymore?" -- Yes, very much so, especially by administrators, developers, and "power users" ... not so much by computer-as-appliance users. Commented Jun 28, 2013 at 0:22

1 Answer 1

0

Yes and yes.

GUI's are sometimes programmed in C++ (C is rarer), but it's also used for console programs. One special type of GUI's is in fact usually done in C++, and that's games. A common example of console programs is a converter program, which takes in one file and creates another. It's UI can be ./tool < InFile > OutFile.

Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.