# binary

## binary相关知识

• Insus Binary Utility
• linux采用binary方式安装mysql
本文实例为大家分享了linux采用binary方式安装mysql的具体步骤，供大家参考，具体内容如下1、下载binary文件　　在官网上下载 mysql-5.6.36-linux-glibc2.5-i686.tar.gz.2、解压文件并移动到/usr/local/mysql目录下?1tar -zxvf mysql-5.6.36-linux-glibc2.5-i686.tar.gz3、创建用户组和用户并配置?1234groupadd mysqluseradd mysql -g mysqlchown -R mysql /usr/local/mysql/chgrp -R mysql /usr/local/mysql/4、安装及初始化?12345678#安装mysql/usr/local/mysql/scripts/mysql_install_db --user=root#配置mysql启动文件cp /usr/local/mysql/support-files/my-default.cnf /etc/my.cnf#
• leetcode 104. Maximum Depth of Binary Tree
Given a binary tree, find its maximum depth. The maximum depth is the number of nodes along the longest path from the root node down to the farthest leaf node. public class Solution { public int maxDepth(TreeNode root) { int depth = 0; if(root != null){ int leftDepth = maxDepth(root.left); int rightDepth = maxDepth(root.right); depth ++; if(leftDepth &lt; rightDepth){ depth = depth + rightDepth; }else{ depth = depth + leftDepth; } } return depth; } }
• 【LEETCODE】模拟面试-108-Convert Sorted Array to Binary Search Tree
图源：新生大学题目：https://leetcode.com/problems/convert-sorted-array-to-binary-search-tree/Given an array where elements are sorted in ascending order, convert it to a height balanced BST.分析：Input: So we&#39;re given a sorted array in ascending order.**Output: ** To return the root of a Binary Search Tree.The corner case is when the input array is null or empty, then we will return null.To build a tree, we need to firstly find the root.And since it&#39;s a BST, wh