原创 LINUX sed - i streaming editor

Problem: The steps that I take:  create table using the following HQL commands:      CREATE TABLE 10projects(......

原创 Median of two Sorted Arrays

class Solution { /** * @param A: An integer array. * @param B: An integer array. * @return: a double

原创 Unique Binary Search Trees II

Given n, generate all structurally unique BST's (binary search trees) that store values 1...n. Idea: Each time we choos

原创 Convert Sorted Array to Binary Search Tree

Given an array where elements are sorted in ascending order, convert it to a height balanced BST. public class Solution

原创 Validate Binary Search Tree

Given a binary tree, determine if it is a valid binary search tree (BST). Assume a BST is defined as follows: 1. The l

原创 Convert Sorted List to Binary Search Tree

Problem : Given a singly linked list where elements are sorted in ascending order, convert it to a height balanced BST.

原创 Copy List with Random Pointer

Problem:  A linked list is given such that each node contains an additional random pointer which could point to any nod

原创 Remove Duplicates from Sorted List II

Fair Remove Duplicates from Sorted List II Show Result My Submissions 28% Accepted Given a sorted linked lis

原创 Reverse Linked List II

Fair Reverse Linked List II Show Result My Submissions 27% Accepted Reverse a linked list from position m t

原创 Interleaving String

Fair Interleaving StringMy Submissions 54% Accepted Given three strings: s1, s2, s3, determine whether s3 is

原创 Reverse Linked List

Easy Reverse Linked List Show Result My Submissions 37% Accepted Reverse a linked list. Example For linked

原创 Construct Binary Tree from Preorder and Inorder Traversal

Fair Construct Binary Tree from Preorder and Inorder Traversal Show Result My Submissions 35% Accepted Give

原创 Unique Permutations

Fair Unique Permutations Show Result My Submissions 16% Accepted Given a list of numbers with duplicate num

原创 Binary Tree Level Order Traversal

Fair Binary Tree Level Order Traversal Show Result My Submissions 30% Accepted Given a binary tree, return t

原创 4 Sum

Fair 4 Sum Show Result My Submissions 19% Accepted Given an array S of n integers, are there elements a, b,