Not Only Algorithm,不仅仅是算法,关注数学、算法、数据结构、程序员笔试面试以及一切涉及计算机编程之美的内容 。。

Leetcode Reverse Integer

Leetcode algorithms 第 7 题:Reverse Integer


Leetcode ZigZag Conversion

Leetcode algorithms 第 6 题:ZigZag Conversion。


Leetcode Longest Palindromic Substring

Leetcode algorithms 第 5 题:Longest Palindromic Substring。


Leetcode Median of Two Sorted Arrays

Leetcode algorithms 第 4 题:Median of Two Sorted Arrays。


Leetcode Longest Substring Without Repeating Characters

Leetcode algorithms 第 3 题:Longest Substring Without Repeating Characters。


Leetcode Add Two Numbers

Leetcode algorithms 第 2 题: Add Two Numbers。


Leetcode Two Sum

Leetcode algorithms 第 1 题: Two Sum。


PAT 1091. Acute Stroke

One important factor to identify acute stroke (急性脑卒中) is the volume of the stroke core. Given the results of image analysis in which the core regions are identified in each MRI slice, your job is to calculate the volume of the stroke core.


PAT 1090. Highest Price in Supply Chain

A supply chain is a network of retailers(零售商), distributors(经销商), and suppliers(供应商)– everyone involved in moving a product from supplier to customer.


PAT 1089. Insert or Merge

According to Wikipedia:

Insertion sort iterates, consuming one input element each repetition, and growing a sorted output list. Each iteration, insertion sort removes one element from the input data, finds the location it belongs within the sorted list, and inserts it there. It repeats until no input elements remain.


PAT 1088. Rational Arithmetic

For two rational numbers, your task is to implement the basic arithmetics, that is, to calculate their sum, difference, product and quotient.


PAT 1087. All Roads Lead to Rome

Indeed there are many different tourist routes from our city to Rome. You are supposed to find your clients the route with the least cost while gaining the most happiness.


PAT 1086. Tree Traversals Again

An inorder binary tree traversal can be implemented in a non-recursive way with a stack. For example, suppose that when a 6-node binary tree (with the keys numbered from 1 to 6) is traversed, the stack operations are: push(1); push(2); push(3); pop(); pop(); push(4); pop(); pop(); push(5); push(6); pop(); pop(). Then a unique binary tree (shown in Figure 1) can be generated from this sequence of operations. Your task is to give the postorder traversal sequence of this tree.


PAT 1085. Perfect Sequence

Given a sequence of positive integers and another positive integer p. The sequence is said to be a "perfect sequence" if M <= m * p where M and m are the maximum and minimum numbers in the sequence, respectively.


PAT 1084. Broken Keyboard

On a broken keyboard, some of the keys are worn out. So when you type some sentences, the characters corresponding to those keys will not appear on screen.

Now given a string that you are supposed to type, and the string that you actually type out, please list those keys which are for sure worn out.


分页: 第一页 «上一页 4567891011121314 下一页 » 最后一页