- 博客(6)
- 资源 (1)
- 收藏
- 关注
转载 List中的set方法和add方法 以及Pascal's Triangle问题
刷同样的题,遇见同样的问题,list的set方法和add方法add方法是在某个指定的位置加上某个对象,并将原来的位置的那个对象向后挤了一格。set方法是将原来位置上的那个给取代了,并将原来位置上对象的返回。转载自https://blog.csdn.net/bug_moving/article/details/52739137import java.util.LinkedList;import j...
2018-03-31 15:24:57 1707
原创 平衡二叉树判断
Given a binary tree, determine if it is height-balanced.For this problem, a height-balanced binary tree is defined as:a binary tree in which the depth of the two subtrees of every node never d
2018-03-31 11:06:12 1616
原创 Convert Sorted Array to Binary Search Tree
Given an array where elements are sorted in ascending order, convert it to a height balanced BST.For this problem, a height-balanced binary tree is defined as a binary tree in which the depth of t
2018-03-31 10:38:19 1599
原创 对称树 问题
给定一个二叉树,判断此树是否是关于自身对称的(即关于它中心对称)For example, this binary tree [1,2,2,3,4,4,3] is symmetric: 1 / \ 2 2 / \ / \3 4 4 3But the following [1,2,2,null,3,null,3] is not: 1 / \ 2 2 ...
2018-03-30 22:38:44 1638
原创 Climbing Stairs
You are climbing a stair case. It takes n steps to reach to the top.Each time you can either climb 1 or 2 steps. In how many distinct ways can you climb to the top?Note: Given n will be a posi
2018-03-30 19:02:55 1570
转载 数据的中心化、标准化和归一化
意义:数据中心化和标准化在回归分析中是取消由于量纲不同、自身变异或者数值相差较大所引起的误差。 原理:数据标准化:是指数值减去均值,再除以标准差; 数据中心化:是指变量减去它的均值。 目的:通过中心化和标准化处理,得到均值为0,标准差为1的服从标准正态分布的数据。归一化方法:1、把数变为(0,1)之间的小数主要是为了数据处理方便提出来
2018-03-29 15:13:38 5761
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人