For this Question: Given a BST containing N nodes. The task is to find the <b>minimum absolute difference</b> possible between any <b>two different nodes</b>.<b>User Task:</b>
Since this will be a functional problem you don't have to take input. You just have to complete the function <b>absMinDist()</b> that takes "root" node as parameter 

<b>Constraints:</b>
1 <= T <= 100
1 <= N <= 10^5
1 <= node values <= 10^5

<b>Sum of N over all testcases does not exceed 10^6</b>

For each testcase you need to return the minimum absolute difference between any two different nodes.The driver code will take care of printing new line.Input:
2
5 3 6
5 N 9 8 N

Output:
1
1

Explanation:
Testcase 1:    
                                     5
                                  /     \
                               3         6
the minimum abs difference between two nodes i.e 5 & 6 is 1.

Testcase 2:     
                                   5
                                /     \
                              N       9
                                       /   \
                                     8     N
the minimum absolute difference between two nodes i.e. 9 & 8 is 1., I have written this Solution Code:  static Integer prev = null, minDiff = Integer.MAX_VALUE;
    public static  int absMinDist(Node root) {
        prev = null;
        minDiff = Integer.MAX_VALUE;
        bst(root);
        return minDiff;
    }

    public static void bst(Node root) {
        if(root==null) return;
        bst(root.left);
        if(prev!=null) {
            minDiff = Math.min(root.data-prev, minDiff);
        }
        prev= root.data;
        bst(root.right);
    }, In this Programming Language: Java, Now tell me if this Code is compilable or not?