原创 圖像的基本幾何變換

文章出處: http://www.cnblogs.com/wangguchangqing/p/4039095.html http://www.cnblogs.com/wangguchangqing/p/4045150.html

原创 Leetcode214: Remove Invalid Parentheses

Remove the minimum number of invalid parentheses in order to make the input string valid. Return all possible results

原创 Leetcode218: Maximum Gap

Given an unsorted array, find the maximum difference between the successive elements in its sorted form. Try to solve

原创 Leetcode221: Sliding Window Maximum

Given an array nums, there is a sliding window of size k which is moving from the very left of the array to the very r

原创 Leetcode213: Longest Consecutive Sequence

Given an unsorted array of integers, find the length of the longest consecutive elements sequence. For example, Given

原创 Leetcode217: Reverse Nodes in k-Group

Given a linked list, reverse the nodes of a linked list k at a time and return its modified list. If the number of n

原创 Leetcode216: Edit Distance

Given two words word1 and word2, find the minimum number of steps required to convert word1 to word2. (each operation

原创 Leetcode224: Sudoku Solver

Write a program to solve a Sudoku puzzle by filling the empty cells. Empty cells are indicated by the character '.'.

原创 Leetcode225: Candy

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

原创 Leetcode227: Best Time to Buy and Sell Stock IV

Say you have an array for which the ith element is the price of a given stock on day i. Design an algorithm to find t

原创 Leetcode220: First Missing Positive

Given an unsorted integer array, find the first missing positive integer. For example, Given [1,2,0] return 3, and [

原创 Leetcode215: Distinct Subsequences

Given a string S and a string T, count the number of distinct subsequences of T in S. A subsequence of a string is a

原创 OpenCV函數cvFindContours輪廓提取

提取輪廓在OpenCV裏有一個函數 cvFindContours 這個函數用起來很方便,但是隨着你使用的深入,你會發現有一些迷惑在這裏。比如當你提取輪廓時只需要最外圍的一個輪廓,但是你會發現當輪廓畫出來時是好幾個;當你需要找一個最大輪廓時

原创 Leetcode211: Populating Next Right Pointers in Each Node II

Follow up for problem "Populating Next Right Pointers in Each Node". What if the given tree could be any binary tree

原创 Leetcode226: Merge k Sorted Lists

Merge k sorted linked lists and return it as one sorted list. Analyze and describe its complexity. 可以借鑑Merge two sorte