public static boolean isValidBST(TreeNode root) {
		if (root == null) {
			return true;
		}
		TreeNode nodeL = root.left;
		TreeNode nodeR = root.right;
		if (nodeL != null) {
			if (nodeL.val >= root.val)
				return false;
			else {
				if (!isValidBSTHelper(nodeL, root, true))
					return false;
			}
		}
		if (nodeR != null) {
			if (nodeR.val <= root.val)
				return false;
			else {
				if (!isValidBSTHelper(nodeR, root, false))
					return false;
				;
			}
		}
		return true;
	}