Hi,
I'm a confused.
i want to learn C++ and I don't know where to start.
I have the following questions.
1. What is the difference between C++ and visual C++ ? Which one is the standard programming language ?
2. What book do you recommend to learn C++ for a beginner ?
3. What are other ways that I can learn C++ easier ?
Thank you
Visual C++ and C++ questions?
c++ and visual c++ are the same thing just that visual makes programming windows app easier (it's pampered).. use bloodshed c++ to learn http://www.bloodshed.net/devcpp.html
book, hmm, i dunno. i learned basic skills using "problem solving with c++" by savitch, the book is alright and will teach you the basic. also anything from o'rileys is pretty good.
checkout these websites http://www.cprogramming.com and http://www.cplusplus.com/ they both have great tutorials
perhaps you should take a course at a local community college.
to start i would get bloodshed and do these tutorails http://www.cprogramming.com/tutorial/les... hit next for the next lesson (bottom of page in red plain text, says "Next:" and what the next lesson is)
Reply:http://yepoocha.blogspot.com
might help Report It
Reply:1) C++ is a language. Visual C++ is Microsoft's C++ compiler. Asking the difference is like asking the difference between a car and a Ford.
2) Hands down, Accelerated C++ ( http://sc.tri-bit.com/Moo for the Amazon referral link.)
3) There really aren't any. C++ is a large language with many pitfalls. You need a good primer book. Be aware that most C++ primer books are utter crap; it's important to get the right one. Accelerated C++ (the link above) is an excellent starting point.
Tuesday, July 14, 2009
C&C Guinea pig cage.....?
Alright I am getting a bigger C%26amp;C cage on Tuesday, and I need some help on where to buy them? No internet sites please, I need different stores where I can get them. My dad bought the stuff for my last C%26amp;C cage, so I don't know where to get the stuff at. And my dad checked to see if they had any more cubes, and they're all gone.
So does anybody else know where I can get the things from?
Goodnight, I'll be back to look at the question in the morning.
~GPSapphire
C%26amp;C Guinea pig cage.....?
It depends where you live, Target and most storage places should sell them, coroplast can be found at any good signmaker. Because I do not know where you are I am going to give you 1 link, this is to a material locater, basically you choose what items you are looking for, add your country and a whole heap of posts will come up with places where other people have got theres materials.
http://www.guineapigcages.com/where.htm
If I knew where you lived I would not give you that link but there are shops in Australia that are not in America/England etc and vice verca, for example Australia does not have Wal-Mart, Petco and Petsmart etc. I recently went to The Reject Shop, they were selling them for about $12, they were called Stack 'N' Rack. As for coroplast, I looked coroplast up in the Yellow pages and came up with a couple of companies who gave me off cuts for dirt cheap.
Good Luck!
Reply:All I know is that they have the storage cubes at Target the last time I went (but that doesn't mean that they'll be there where you live). You could also check Staples or K-Mart or Wal-Mart.
Reply:I got all my cubes from Target for like 14.99. If you get them from K-mart, the grids are extra wide and might throw off your measurments. I got my coroplast from Fast Signs. Just about any sign store will sell you some coroplast. Just a sidenote: if they charge you more than 20 for a plain piece of coroplast, they're overcharging you. I got a 4' x 8' for $13.
So does anybody else know where I can get the things from?
Goodnight, I'll be back to look at the question in the morning.
~GPSapphire
C%26amp;C Guinea pig cage.....?
It depends where you live, Target and most storage places should sell them, coroplast can be found at any good signmaker. Because I do not know where you are I am going to give you 1 link, this is to a material locater, basically you choose what items you are looking for, add your country and a whole heap of posts will come up with places where other people have got theres materials.
http://www.guineapigcages.com/where.htm
If I knew where you lived I would not give you that link but there are shops in Australia that are not in America/England etc and vice verca, for example Australia does not have Wal-Mart, Petco and Petsmart etc. I recently went to The Reject Shop, they were selling them for about $12, they were called Stack 'N' Rack. As for coroplast, I looked coroplast up in the Yellow pages and came up with a couple of companies who gave me off cuts for dirt cheap.
Good Luck!
Reply:All I know is that they have the storage cubes at Target the last time I went (but that doesn't mean that they'll be there where you live). You could also check Staples or K-Mart or Wal-Mart.
Reply:I got all my cubes from Target for like 14.99. If you get them from K-mart, the grids are extra wide and might throw off your measurments. I got my coroplast from Fast Signs. Just about any sign store will sell you some coroplast. Just a sidenote: if they charge you more than 20 for a plain piece of coroplast, they're overcharging you. I got a 4' x 8' for $13.
C++, Visual C++, or Java 2, HELP, I Need Guidance, No this question is not hard to answer, so just look please
bla bla bla bla bla...
Im very smart, but I need Your help, what should I learn C++ Visual C++ or Java 2.. I would Like to build programs with color, GUI's thats "Graphical User Interfaces" People.
Nice Little Programs that have fancy little buttons, .I know HTML, JavaScript and a lil bit of Java 2 and C++, but I need a lil guidance, HELP !!!! omg, Id like to start programming somtime tonight, and im sure once i have a good grip on C++ or Java 2, that Ill run with it, so point me in the right direction and ill be on my mary little way, give me what I want and ill go away... lol, j/k, I need help I need some guidance, I need help, Im not stupid, but I am a little lazy. Im usally use to just putting words images, tables, videos, mp3 music players, and all that crap on sites, but i would like to start some serious programming, like network programms, that make it possible for remote access, no im not a hacker, and no I will not turn out to be a hacker, that I know of, but just respond..
C++, Visual C++, or Java 2, HELP, I Need Guidance, No this question is not hard to answer, so just look please
If you're lazy then simply put, pick Java. It can't get easier to make GUIs in a blink of an eye.
For C++, you need a GUI Toolkit, like WxWidgets
http://www.wxwidgets.org/
Which is more complicated and will require more perseverance.
Reply:The first thing you need to do is to remove caffeine from your diet. The second is to not use terms like omg.
alstroemeria
Im very smart, but I need Your help, what should I learn C++ Visual C++ or Java 2.. I would Like to build programs with color, GUI's thats "Graphical User Interfaces" People.
Nice Little Programs that have fancy little buttons, .I know HTML, JavaScript and a lil bit of Java 2 and C++, but I need a lil guidance, HELP !!!! omg, Id like to start programming somtime tonight, and im sure once i have a good grip on C++ or Java 2, that Ill run with it, so point me in the right direction and ill be on my mary little way, give me what I want and ill go away... lol, j/k, I need help I need some guidance, I need help, Im not stupid, but I am a little lazy. Im usally use to just putting words images, tables, videos, mp3 music players, and all that crap on sites, but i would like to start some serious programming, like network programms, that make it possible for remote access, no im not a hacker, and no I will not turn out to be a hacker, that I know of, but just respond..
C++, Visual C++, or Java 2, HELP, I Need Guidance, No this question is not hard to answer, so just look please
If you're lazy then simply put, pick Java. It can't get easier to make GUIs in a blink of an eye.
For C++, you need a GUI Toolkit, like WxWidgets
http://www.wxwidgets.org/
Which is more complicated and will require more perseverance.
Reply:The first thing you need to do is to remove caffeine from your diet. The second is to not use terms like omg.
alstroemeria
C++ Programmers!! help!!?
there's an error in this code... can you help me repair it?!
#include %26lt;stdio.h%26gt;
#include %26lt;stdlib.h%26gt;
#include %26lt;conio.h%26gt;
#include %26lt;string.h%26gt;
void initval();
int chars[255];
int main()
{
FILE *file_r;
int ferr = 0, i;
char filename[50];
while (ferr == 0)
{
system("cls");
printf("Enter file name: ");
gets(filename);
file_r = fopen(filename, "r");
if (file_r == 0)
{
printf("Error! File does not exist!");
getch();
}
else
{
ferr = 1;
}
}
char *r;
char c, ctr = 0;
while ((c = getc(file_r)) != EOF)
{
ctr++;
}
fclose(file_r);
file_r = fopen(filename, "r");
char string[ctr];
i = -1;
while ((c = getc(file_r)) != EOF)
{
i++;
string[i] = c;
}
printf("\n%s", string);
printf("\n\n%s\n\n", strrev(string));
//tig-ihap
for (i = 0; i %26lt; strlen(string); i++)
{
chars[string[i]]++;
}
for (i = 0; i %26lt; 256; i++)
{
if (chars[i] != 0)
{
printf("%c = %d\n", i, chars[i]);
}
}
getch();
fclose(file_r);
return 0;
}
void initval()
{
int i;
for (i = 0; i %26lt; 256; i++)
{
chars[i] = 0;
}
}
C++ Programmers!! help!!?
do this:
char [] string = new char [ctr];
and don't forget
delete [] string
at the end to free up the memory
Reply:from the code you provided i copy and paste it on my system and i recieved no error messages and the program ran fine most likely it has to do with your compiler in my unix based system it didn't recongize the conio.h header file try using a different compiler
Reply:you cant declare a char string that way (char string[ctr]). the length of the string has to be a constant size such as "char string[20];". as the other person said, you could also do this "char [] string = new char [ctr];"
Reply:The code you're using isn't C++, it's just C. It'd help if you listed the error.
#include %26lt;stdio.h%26gt;
#include %26lt;stdlib.h%26gt;
#include %26lt;conio.h%26gt;
#include %26lt;string.h%26gt;
void initval();
int chars[255];
int main()
{
FILE *file_r;
int ferr = 0, i;
char filename[50];
while (ferr == 0)
{
system("cls");
printf("Enter file name: ");
gets(filename);
file_r = fopen(filename, "r");
if (file_r == 0)
{
printf("Error! File does not exist!");
getch();
}
else
{
ferr = 1;
}
}
char *r;
char c, ctr = 0;
while ((c = getc(file_r)) != EOF)
{
ctr++;
}
fclose(file_r);
file_r = fopen(filename, "r");
char string[ctr];
i = -1;
while ((c = getc(file_r)) != EOF)
{
i++;
string[i] = c;
}
printf("\n%s", string);
printf("\n\n%s\n\n", strrev(string));
//tig-ihap
for (i = 0; i %26lt; strlen(string); i++)
{
chars[string[i]]++;
}
for (i = 0; i %26lt; 256; i++)
{
if (chars[i] != 0)
{
printf("%c = %d\n", i, chars[i]);
}
}
getch();
fclose(file_r);
return 0;
}
void initval()
{
int i;
for (i = 0; i %26lt; 256; i++)
{
chars[i] = 0;
}
}
C++ Programmers!! help!!?
do this:
char [] string = new char [ctr];
and don't forget
delete [] string
at the end to free up the memory
Reply:from the code you provided i copy and paste it on my system and i recieved no error messages and the program ran fine most likely it has to do with your compiler in my unix based system it didn't recongize the conio.h header file try using a different compiler
Reply:you cant declare a char string that way (char string[ctr]). the length of the string has to be a constant size such as "char string[20];". as the other person said, you could also do this "char [] string = new char [ctr];"
Reply:The code you're using isn't C++, it's just C. It'd help if you listed the error.
To learn C++ you must ... ?
To learn C++ you must ...
a) Attend a lecture on the subject.
b) Learn C first and then the ++ part
c) Buy a good book on C++ like: _____
d) Learn it from an online internet source, like _____
e) Forget Microsoft Visual C++ and get a UNIX emulator
f) forget C++ and learn the language _______
g) forget C++, It's way to difficuilt man!
h) other advice.
To learn C++ you must ... ?
The way I did it was to learn C first, then C++, but that was many many years ago. Now people are in love with crap languages like Java and C#. Any language that hides pointers from the developer is a toy/joke. I love the control that C and C++ give you, but I digress....
The way I learned was I got one of those Teach yourself C in 21 Days books. Went through that to get the basics, did the same for C++, and after I had the basics from both books, I picked up the rest of years of programming for projects or just for fun.
You can pick up just about everything from the internet now, so you don't need to buy a book, but I like having an easy reference.
Books I would recommend is
"The C Programming Language" by Kernighan and Ritchie
and
"The C++ Programming Language" by Bjarne Stroustrup
Side note: I suggest E as well. Forget Macro$loth and go to linux.
Reply:i) Copy from your neighbour's book!!!
Reply:The best thing to do is to just go out and buy the software package if you can afford it. The package should contain books that will teach you about the many functions that are essential to make a use full program that you might not get anywhere else.
Reply:b) Learn C first
b+) Learn about object oriented design (don't worry about C++ just yet)
b++) Then as you are picking up C++, think about the OOD stuff you've learn. If you think in terms of OOD, C++ becomes a lot clearer and you'll suddenly realize why that have so much junk in it.
c) Get "The C++ Programming Language" by Stoustrup
e) Hmm...if you are cool with b and c, VC++ ain't so bad. In fact, you'll also "get" what VC++ is trying to do if you think more in terms of OOD and code reuse.
h) Don't become overwhelmed by C++. Yeah its a lot but you probably won't use most of it but you want to be aware of it.
h+) Oh and get used to using the STL. Once you get used to using the STL, it'll make programming a whole lot easier for many of the mundane tasks.
Reply:C++ for dummies.
Reply:B and C if you want to educate yourself and have a solid structure from which to draw. I recommend the Sams books for a beginner.
D and A if you want to go it at school. I wouldn't bother with ITT or DeVry since you can't transfer the credits you get there to a normal university should you some time down the road rethink your education and want to get a Master's on top of your Bachelor's or Associates.
E since its only a matter of years before Microsoft goes under and I wouldn't bother with their stuff if you paid me a million bucks.
Reply:wat's ur question?
a) Attend a lecture on the subject.
b) Learn C first and then the ++ part
c) Buy a good book on C++ like: _____
d) Learn it from an online internet source, like _____
e) Forget Microsoft Visual C++ and get a UNIX emulator
f) forget C++ and learn the language _______
g) forget C++, It's way to difficuilt man!
h) other advice.
To learn C++ you must ... ?
The way I did it was to learn C first, then C++, but that was many many years ago. Now people are in love with crap languages like Java and C#. Any language that hides pointers from the developer is a toy/joke. I love the control that C and C++ give you, but I digress....
The way I learned was I got one of those Teach yourself C in 21 Days books. Went through that to get the basics, did the same for C++, and after I had the basics from both books, I picked up the rest of years of programming for projects or just for fun.
You can pick up just about everything from the internet now, so you don't need to buy a book, but I like having an easy reference.
Books I would recommend is
"The C Programming Language" by Kernighan and Ritchie
and
"The C++ Programming Language" by Bjarne Stroustrup
Side note: I suggest E as well. Forget Macro$loth and go to linux.
Reply:i) Copy from your neighbour's book!!!
Reply:The best thing to do is to just go out and buy the software package if you can afford it. The package should contain books that will teach you about the many functions that are essential to make a use full program that you might not get anywhere else.
Reply:b) Learn C first
b+) Learn about object oriented design (don't worry about C++ just yet)
b++) Then as you are picking up C++, think about the OOD stuff you've learn. If you think in terms of OOD, C++ becomes a lot clearer and you'll suddenly realize why that have so much junk in it.
c) Get "The C++ Programming Language" by Stoustrup
e) Hmm...if you are cool with b and c, VC++ ain't so bad. In fact, you'll also "get" what VC++ is trying to do if you think more in terms of OOD and code reuse.
h) Don't become overwhelmed by C++. Yeah its a lot but you probably won't use most of it but you want to be aware of it.
h+) Oh and get used to using the STL. Once you get used to using the STL, it'll make programming a whole lot easier for many of the mundane tasks.
Reply:C++ for dummies.
Reply:B and C if you want to educate yourself and have a solid structure from which to draw. I recommend the Sams books for a beginner.
D and A if you want to go it at school. I wouldn't bother with ITT or DeVry since you can't transfer the credits you get there to a normal university should you some time down the road rethink your education and want to get a Master's on top of your Bachelor's or Associates.
E since its only a matter of years before Microsoft goes under and I wouldn't bother with their stuff if you paid me a million bucks.
Reply:wat's ur question?
C++ Shunting_yard_algorithm?
The only prog. i can find is for c but i need the code for C++ i know c code will work on c++ but i dont understand c
The objective is to implement an infix to
postfix RPN notation converter using a stack. There is a good description of the shunting yard
algorithm described by Edsgar Dijkstra at http://en.wikipedia.org/wiki/Shunting_ya...
There is an example of the algorithm in the link. The infix notation string should be entered through standard input and the
postfix notation conversion displayed on standard output.
The stack used in this project should be written as a class and using a linked list to implement the
stack data structure.
C++ Shunting_yard_algorithm?
I have written this program in Java, it is not that different from C or C++, there is an algorithm for converting:
Scan the Infix string from left to right.
1- Initialise an empty stack.
2- If the scannned character is an operand, add it to the Postfix string. If the scanned character is an operator and if the stack is empty Push the character to stack.
3- If the scanned character is an Operand and the stack is not empty, compare the precedence of the character with the element on top of the stack (topStack). If topStack has higher precedence over the scanned character Pop the stack else Push the scanned character to stack. Repeat this step as long as stack is not empty and topStack has precedence over the character.
Repeat this step till all the characters are scanned.
4- (After all characters are scanned, we have to add any character that the stack may have to the Postfix string.) If stack is not empty add topStack to Postfix string and Pop the stack. Repeat this step as long as stack is not empty.
5- Return the Postfix string.
Check out:
http://scriptasylum.com/tutorials/infix_...
for more details, i copied and pasted the algorithm from this site, there are also some examples there.
The Java code is too long to send it here, if u want it, e-mail me and i will send it.
Good luck
Bye
The objective is to implement an infix to
postfix RPN notation converter using a stack. There is a good description of the shunting yard
algorithm described by Edsgar Dijkstra at http://en.wikipedia.org/wiki/Shunting_ya...
There is an example of the algorithm in the link. The infix notation string should be entered through standard input and the
postfix notation conversion displayed on standard output.
The stack used in this project should be written as a class and using a linked list to implement the
stack data structure.
C++ Shunting_yard_algorithm?
I have written this program in Java, it is not that different from C or C++, there is an algorithm for converting:
Scan the Infix string from left to right.
1- Initialise an empty stack.
2- If the scannned character is an operand, add it to the Postfix string. If the scanned character is an operator and if the stack is empty Push the character to stack.
3- If the scanned character is an Operand and the stack is not empty, compare the precedence of the character with the element on top of the stack (topStack). If topStack has higher precedence over the scanned character Pop the stack else Push the scanned character to stack. Repeat this step as long as stack is not empty and topStack has precedence over the character.
Repeat this step till all the characters are scanned.
4- (After all characters are scanned, we have to add any character that the stack may have to the Postfix string.) If stack is not empty add topStack to Postfix string and Pop the stack. Repeat this step as long as stack is not empty.
5- Return the Postfix string.
Check out:
http://scriptasylum.com/tutorials/infix_...
for more details, i copied and pasted the algorithm from this site, there are also some examples there.
The Java code is too long to send it here, if u want it, e-mail me and i will send it.
Good luck
Bye
C# Questions - Please Help ASAP!?
i am having some difficulty with these C# questions! i will give you the questions and 4 possible answers, please can you provide me with the correct answer and please explain how you got that answer.... thanks in advance
4. What does the following algorithm output for n=3?
set sum to zero.
set i to 1.
input n.
while i is less than or equal to n do
{
add i to sum.
increment i.
}
output sum.
a. 1
b. 9
c. 6
d. 3
5. What would be output by the following section of C#?
int A[5] = {1 , 2, 3, 4};
int i;
for (i=0; i%26lt;5; i++)
{
A[i] = 2*A[i];
Console.WriteLine (A[i]);
}
a. 2
b. 4
c. 6
d. 8
6. What output will the following code produce?
int x = 4;
int y = 7;
Console.WriteLine(x+y);
a. 7
b. 11
c. (x + y)
d. 4
C# Questions - Please Help ASAP!?
That is a lot of work to ask in this category. Suggest you reask in the "homework help" category.
primrose
4. What does the following algorithm output for n=3?
set sum to zero.
set i to 1.
input n.
while i is less than or equal to n do
{
add i to sum.
increment i.
}
output sum.
a. 1
b. 9
c. 6
d. 3
5. What would be output by the following section of C#?
int A[5] = {1 , 2, 3, 4};
int i;
for (i=0; i%26lt;5; i++)
{
A[i] = 2*A[i];
Console.WriteLine (A[i]);
}
a. 2
b. 4
c. 6
d. 8
6. What output will the following code produce?
int x = 4;
int y = 7;
Console.WriteLine(x+y);
a. 7
b. 11
c. (x + y)
d. 4
C# Questions - Please Help ASAP!?
That is a lot of work to ask in this category. Suggest you reask in the "homework help" category.
primrose
Subscribe to:
Posts (Atom)