Beginners - May 2009 (Page 19)

Can't convert string to char**
 
OK, I think you guys are all busy so I'll just put the code line which has error and I think you Masters of dark secrets of C++ will know this one. This is the...
[5 replies] Last: Thanks to both of you! (by arnes99)
What does this error mean?!?!
 
I am getting this error message when I run my program, what does it mean?! terminate called after throwing an instance of 'std::bad_alloc' what(): std::...
[2 replies] Last: well that's odd because it doesn't really seem like I am accessing too... (by satchmo05)
Triangle problem
 
I'm new and I'm trying to figure out the problems with this triangle but can't after a week of trying. If I could just see the right code I think I would under...
[1 reply] : why is the function an int if its return value has no impact? (Make it... (by Warnis)
Arrays and Functions
 
This program is for receiving user int input and processing it with specified functions. I am stuck on two functions. Problem 1: The minimum index value of u...
[13 replies] Last: sorry, the code i put up returns the minimum value, but not it's inde... (by mcleano)
by Bv202
Got trouble understanding Pointers
 
Hey, I'm now learning how to use Pointers, but I'm stuck already. int* FirstPointer = &Variable; That will work. But when using an array, it MUST be th...
[12 replies] Last: A bit yes, thanks :) (by Bv202)
by Null
Waiting for input
 
Hello, I decided to create a simple console game (something like tennis) but i have a problem. Example: void obj_move(x,y){ // do something // maybe move ...
[3 replies] Last: Suppose you function is called getinput() and takes no parameters, you... (by helios)
by MatieA
24 hour time conversion
 
Hi there, This is code for converting 24hr time to 12 hr time. I'm getting an error message that disply is not being initialized, and also I haven't been ...
[3 replies] Last: Thus, the function for doing the conversions will have a call-by-refe... (by helios)
by jayt
how to create a .cpp and .h file (1,2)
 
Hello , I am new c plus plus student. I read this tutorial and it looks a good one.I will be glad if someone tells me how to create a .cpp and .h files for a pr...
[25 replies] Last: How can I with functions in header file modifed variables in .cpp file... (by jasmin m)
makefile to create a shared object library
 
my makefile: DRIVER_SRC = PumaDriver.cpp PumaBody.cpp PumaMotor.cpp base_manipulation.cpp serialPort.cpp DRIVER_INC = PumaDriver.h PumaBody.h PumaMotor.h b...
[2 replies] Last: ok. i missed on thing.. dependencies of the headers.. lets say main.cp... (by writetonsharma)
The Different using "include" and "class"
 
Dear, I don't really understand the difference between using include and adding a class. For example: using include : +++++++++++++++++++++++ // First cas...
[2 replies] Last: //Second case class myB { class myA; . . } if you ... (by writetonsharma)
What should i do next?
 
I have been learning C and C++ over the last few years... My problem is i don't know where to go next. I know how to use pointers, classes etc... in C++ but ...
[6 replies] Last: computerquip:Which are the basics and the advanced? (by ShadowReaper)
Problems with display
 
I figured out the reason behind the scenes of my last post; however, I have a problem that I want to get solved. My code that is useful to this post is below: ...
[no replies]
by mk2008
Vector addition using class and operator overload
 
Hello, I'm trying to implement addition of two multidimensional vectors, i.e (M x 2), using operator overload, which is very similar to the example given in th...
[1 reply] : You do not use "sizeof" to get the size of the vector. Use vector::siz... (by Zhuge)
by jayt
Question about .h File
 
Hello , I am learning about how to create .h files.If there is a program and it has one class in it and member functions in it.I know we include all the declar...
[1 reply] : I'm not sure I understand, but if you mean variables local to the func... (by Zhuge)
by lerwys
cout precedence doubt
 
Hello. I was using cout, and something happened that I wasn't expecting. #include <iostream> using namespace std; int returnI(); int i = 0; i...
[1 reply] : The order of the function calls is undefined. You are only guaranteed ... (by Duthomhas)
by lerwys
Changing text color
 
Hi all, I want to change ONLY the foreground color text of my console aplication, not the background text color nor the console background color. In Other wo...
[5 replies] Last: *sigh* ...And something people should be fired for doing. Don't use s... (by Duthomhas)
What is wrong with my selection sort function?
 
What is wrong with my selection sort function? I am trying everything. void sort(int array , int numts) { int lowIndex, lowest; for (int count = 0;...
[3 replies] Last: Something like this? void selectionSort(int array , int numts) ... (by musique)
How to construct/declare this kind of recursivity ?
 
Hello cplusplus forum (first post) I need some help to construct or declare this kind of recursivity: I have 2 classes A and B. Both, A and B, have a set...
[5 replies] Last: I see. Maybe you could help me understand with the program example bel... (by MarcioAB)
by upo
Input problem
 
Hey there guys, I am facing a problem I have successfully implemented my c++ code to manipulate a string, but the problem is that I want my program to ask the...
[5 replies] Last: Yes, just tack it on to the end of the sum string. string all_word... (by Duthomhas)
by nanger
about polymorphism
 
using namespace std; class Base { int a; public: virtual void result(){cout<<"in base\n";} }; class Derived : public Base { public:...
[2 replies] Last: The object is still of type Derived as mentioned above. You can cast i... (by messenjah)
May 2009 Pages: 1... 1718192021
  Archived months: [apr2009] [jun2009]

This is an archived page. To post a new message, go to the current page.