given a sorted (increasing order) array, write an algorithm to create a binary tree with
minimal height
# Include <iostream> using namespace STD; typedef int data; struct node {node (data d): Data (d) {left = right = NULL ;}; data; node * left; node * right;}; class tree {public: tree (): Root (null) {}; node * root; void build (data [], int from, int to, node ** node) {If (from> to) return; int mid = (from + to)/2; * node = new node (data [Mid]); Build (data, from, mid-1, & (* node)-> left); Build (data, Mid + 1, to ,& (* Node)-> right) ;}; void inorderprint (node * node) {If (node = root) cout <"Print:" <Endl; if (node! = NULL) {inorderprint (node-> left); cout <node-> data <""; inorderprint (node-> right);} If (node = root) cout <Endl <"end" <Endl ;};}; int main () {TREE tree; data [] = {1, 2, 3, 4, 5}; tree. build (data, 0, sizeof (data)/sizeof (data)-1, & tree. root); tree. inorderprint (tree. root); System ("pause ");};