• Categories

  • your are stumbler#

    • 26,496
  • Author

  • Recent comments:

    over at this website on Interesting read about Interne…
    Gmail Inbox Tabs and… on Malkovich Bias
    guptaradhesh on Yahoo acquires Tumblr! Great…
  • Advertisements

Posts Tagged ‘mirror of a binary tree’

create Mirror of a Binary Tree

Posted by guptaradhesh on December 8, 2010

a solution pseudo-code to this using recursion is as:

mynode *createMirror (mynode *root)
mynode *temp;


temp = (mynode *) malloc(sizeof(mynode));
temp->value = root->value;

temp->left = createMirror(root->right);
temp->right = createMirror(root->left);



Posted in puzzles/ algorithms | Tagged: , , | Leave a Comment »