原创 Unity開發-3D數學基礎

一    3D數學介紹        1D——數軸。        2D——兩條相交數軸,兩條數軸度量單位相等則稱爲笛卡爾座標系。        3D——空間直角座標系,分爲左手/右手座標系:大拇指 - x軸,食指 - y軸, 其餘三指

原创 十六週

19. Remove Nth Node From End of List Given a linked list, remove the nth node from the end of list and return its head.

原创 第十四周

91. Decode Ways A message containing letters from A-Z is being encoded to numbers using the following mapping: 'A' -> 1

原创 k生成樹問題

k-生成樹(k-SPANDING TREE)問題是這樣的: 輸入:無向圖G=(V,E)。 輸出:G的生成樹,其中所有節點度數不超過k。 如果該樹存在,請證明對任意k>=2: (a)k-生成樹問題是搜索問題。 搜索問題要求:已知起始狀

原创 第八週——135. Candy

135. Candy There are N children standing in a line. Each child is assigned a rating value. You are giving candies to th

原创 第十三週

Given a string which contains only lowercase letters, remove duplicate letters so that every letter appear once and onl

原创 第十五週

87. Scramble String Given a string s1, we may represent it as a binary tree by partitioning it to two non-empty substri

原创 第十週

63. Unique Paths II Now consider if some obstacles are added to the grids. How many unique paths would there be? An ob

原创 算法第二週: Divide and Conquer-分治算法

分治算法基本思想:將問題分解爲k個子問題,每個子問題相互獨立且與原問題性質相同,求得子問題的解即可求得原問題的解。若子問題還較難以解決,就遞歸的分解子問題,直到可以找到簡單的求解方法。 53. Maximum Subarray F

原创 算法第五週——貪心算法

55. Jump Game Given an array of non-negative integers, you are initially positioned at the first index of the array.Eac

原创 第九周

62. Unique Paths A robot is located at the top-left corner of a m x n grid (marked 'Start' in the diagram below). The r

原创 第十二週

Given a collection of candidate numbers (C) and a target number (T), find all unique combinations in C where the candid

原创 算法第六週——回溯

17. Letter Combinations of a Phone Number Given a digit string, return all possible letter combinations that the number

原创 第十一週

575. Distribute Candies Given an integer array with even length, where different numbers in this array represent differ

原创 Leetcode-133. Clone Graph

133. Clone Graph Clone an undirected graph. Each node in the graph contains a label and a list of its neighbors. We us