For some reason my computer will not display red, certain shades of green, orange, and certain shades of purple. Red, for instance, appears as black now.
My father attempted to install some USB...
Type: Posts; User: Nakeerb
For some reason my computer will not display red, certain shades of green, orange, and certain shades of purple. Red, for instance, appears as black now.
My father attempted to install some USB...
For some reason my computer will not display red, certain shades of green, orange, and certain shades of purple. Red, for instance, appears as black now.
My father attempted to install some USB...
It must be something small, this entire program works fairly well
//This is the header file "binary_tree.h"
//===========================/=/=/=/=/=/=/=========================//
// STRUCTURES //...
I rewrote another program that does the same based on the psuedocode I was given today at around noon. However it still does not work. I know I am going off on an extreme tangent by posting this, but...
So I can do this for all functions? When would I need to append to right side or left?
Does this have anything to do with checking for left?
Alright there we go. Alignments fixed
With the help of Nick I am coming very close to being able to insert data into this binary tree... yet some parts still refuse to work.
Here is the entire code segment thus far
#include...
void traverseInOrder(node *root){
if (!root) //test first to see if done
return;
traverseInOrder(root->left);
cout << root->data << " ";
traverseInOrder(root->right);
}
Is there any place I can talk to you besides this board?
Urg I just give up. I am never going to get this done. the struct is a simple
struct node{
char data;
node *left, *right;
}
that's it.
I don't know how I'd insert into a tree using...
I do not understand what that all meant, URG I am dead
An int cannot hold a char value such as a letter, and ints can only hold so much data before overflow errors occur. You can prevent it by making sure the input is less than or equal to MAX_INT in...
This is difficult ;-; must be careful
This also does not build the binary tree in terms of a node holding an operator as data, with two children being separate nodes with integers as the data
Ahh I see how it works. I need to modify it though, this does not work for expressions like "(((3+4)-3)-2)" because it only checks for numbers before and after, not when you have two parentheses next...
Helllp!
No one can help? ;-; I am so dead
Dangit, Salem what do you mean ;-;
And what about nested parenthesis?
I take it none of you use a Mac
The problem states there will always be parenthesis. Any operand-operator-operand statement has ( and ) around it
Also the problem speaks of writing constructors for two types of nodes, one that...
Hmmm, does this also work for nested parenthetical statements? You'd have to detect the first ), yes, but then the items before it and after the last (?
I tried it again and I still can't figure it out. How the heck am I supposed to do this?