Hello, I'm a complete beginner at C++, and I wanted to ask some n00b questions. I couldn't find/understand answers anywhere on the web, nor on these forums...so, here they are:
1. What's the differrence between:
andCode:char a;
I know, it's a pointer, but why do people use char *a more than just 'char a'? What's the purpose of it? How can I use it and find it useful?Code:char* a
2. How to use volatile?
3.Again, why * ?Code:*pVal = atof(szVolAdjust);
4. Is network programming easy?
5. How to get the value of getch() into a variable?
6.What's the use of static here?Code:static void cap_set_pg()
7. Why can't dev-c++ compile most of those complex programs?
8.andCode:struct b{ int g; char *jam; char* unjam; }
What's the use of typedef here?Code:typedef struct{ int g; char *jam; char* unjam; }
9. How to make the program quit if(quit=1) ?
10. How to make my program to open another program? (For example, a CD autorun program shows welcome message, and then opens the folder of CD contents)
11. Program:
file.txt:Code:#include <iostream> #include <fstream> using namespace std; int main() { ofstream read("file.txt"); int count; int count2; cout<<count<<"\n"<<count2; cin.get(); }
How to make the program assign the values from file.txt into variables count and count1?Code:count1=4 count=8
12. How to access a structure from a class?
13. How to get the cout<<'ed text into a variable?Code:class fragile { public: fragile(); ~fragile(); struct tnt { int h; }; }; int main() { fragile fr; fr.tnt dyna; fr.dyna.h=6; //doesnt work
14. Whats the use of '?' in C++?
15. What is union REGS?
16. What is?Code:extern int *a;
Sorry for such stupid questions, I know you won't want to waste your time to answer them, but please understand me, I want to strenghten my C++ knowledge and help others too.



LinkBack URL
About LinkBacks


