From 8b3b46f8cc12d88188fb65020c5c425b0b8e47b6 Mon Sep 17 00:00:00 2001 From: Krishna Vedala Date: Mon, 25 May 2020 18:42:40 -0400 Subject: [PATCH] delete misplaced file --- 872.c | 43 ------------------------------------------- 1 file changed, 43 deletions(-) delete mode 100644 872.c diff --git a/872.c b/872.c deleted file mode 100644 index 577a3c9f..00000000 --- a/872.c +++ /dev/null @@ -1,43 +0,0 @@ -/** - * Definition for a binary tree node. - * struct TreeNode { - * int val; - * struct TreeNode *left; - * struct TreeNode *right; - * }; - */ - - -bool leafSimilar(struct TreeNode* root1, struct TreeNode* root2){ - int sequence1[100] ={0}, sequence2[100]={0}, num_of_node1 =0,num_of_node2 =0; - - num_of_node1 = sequence(root1,sequence1,num_of_node1); - num_of_node2 = sequence(root2,sequence2,num_of_node2); - - if (num_of_node1 != num_of_node2) - return false; - - for (int i = 0;ileft && !root->right){ - list[num_of_node] = root->val; - num_of_node ++; - return num_of_node; - } - - num_of_node = sequence(root->left ,list , num_of_node); - num_of_node = sequence(root->right ,list , num_of_node); - - return num_of_node; -}