Do you know the name of it? or do you have the link? I could not find anything....
Type: Posts; User: lord
Do you know the name of it? or do you have the link? I could not find anything....
I'm new to using GUI's/graphics in C++ but it's come time to learn. I was wondering if anyone knew where I could use an open source 2d grid that would allow me to lite-up certain cells of the grid. ...
error was found finally in this statement:
cout<<"0x "<<hexadecimal[1]<<" "<<hexadecimal[0]<<cout<<"\t";
CODE: http://pastebin.com/d425b7541
I've uploaded all my code and commented on the lines where garbage is coming out.
It didn't seem to help when added + '0' to the switch statement. Maybe if...
I'm not sure why but both my functions are couting garbage on certain elements for only a temporary period of time. I can't figure it out. Is it the way I am initializing the vectors? It is happening...
I think I know what the problem is...
Daved. in the called function I was reading into input >> data the last character of the file... when it returned to main I input >> data again....
...
It is outputting the x... you can explain the problem a little more?
I am doing something funny, then -- I don't see it, though:
void readInput(istream& input, char data)
.
.
.
int main
How do I pass an istream to a function so that when the function is finished the input is at the last character read? I have tried passing by reference...
void readInput(istream& input)
{
....
For a current project I am creating I decided the best way to implement the code would be through an adjacency list. I am just simply confused on what the structs would look like and how to create...
perfect... thanks for that
I don't know what the values of the keys are. They can be random characters.
That's what I am trying to do. But I can't figure out how to iterate through the maps keys without going through its values. For example,
keys: values:
a 1 2 3
b 4 5 ...
Is there anyway to iterate through the keys of a map without having to go through each of the keys values first?
Or is there a way to jump to the next key?
Thanks tabstop! ... why was I not doing that in the first place?
I see what your saying (I think)... For example, class one has a function called a() that creates the first linked list, I just create an object from class two (call it e) and call e.a() .... then...
The linked lists have different designs. But are you saying move current from class one into class two? Then the functions from class one do not have access to it...
The second class builds a linked list that depends on how the first class created its own linked list. I do not want the second class to view it as NULL...
How can I allow class two to share current with class one?
So what I am trying to do is not only have access to the protected stuff in class one but have all the values remain intact when using them from class two.
sorry, I fixed it... Do you know what I am trying to do now? sorry about that
tabstop: what I am trying to do is have access to the node in class one...
This is a general outline of my code. I am wondering why I have trouble accessing the protected members as such. Please let me know if what I have written is not enough info:
struct node
{...
Bubba: I have it working with one class it is just ugly. I have two find_height() functions -- one for the first tree; the other for the second tree. I also have two top() functions, etc.
Here is...
In my base class I have a function print() that prints the heights of all trees. Print() calls find_height() for my base class and derived classes. But find_height() is a virtual function, so it only...