<?xml version="1.0" encoding="utf-8" ?><rss version="2.0"><channel><title><![CDATA[katrina95的博客]]></title><description><![CDATA[]]></description><link>https://blog.youkuaiyun.com/katrina95</link><language>zh-cn</language><generator>https://blog.youkuaiyun.com/</generator><copyright><![CDATA[Copyright &copy; katrina95]]></copyright><item><title><![CDATA[Codeless Code Case1 Small Stuff]]></title><link>https://blog.youkuaiyun.com/katrina95/article/details/129213886</link><guid>https://blog.youkuaiyun.com/katrina95/article/details/129213886</guid><author>katrina95</author><pubDate>Sat, 25 Feb 2023 12:07:28 +0800</pubDate><description><![CDATA[Codeless Code的译文和我对文章的理解]]></description><category></category></item><item><title><![CDATA[1109. Corporate Flight Bookings]]></title><link>https://blog.youkuaiyun.com/katrina95/article/details/102126208</link><guid>https://blog.youkuaiyun.com/katrina95/article/details/102126208</guid><author>katrina95</author><pubDate>Sat, 05 Oct 2019 07:25:52 +0800</pubDate><description><![CDATA[There are n flights, and they are labeled from 1 to n.
We have a list of flight bookings.  The i-th booking bookings[i] = [i, j, k] means that we booked k seats from flights labeled i to j inclusive.
...]]></description><category></category></item><item><title><![CDATA[787. Cheapest Flights Within K Stops]]></title><link>https://blog.youkuaiyun.com/katrina95/article/details/102125458</link><guid>https://blog.youkuaiyun.com/katrina95/article/details/102125458</guid><author>katrina95</author><pubDate>Sat, 05 Oct 2019 07:10:44 +0800</pubDate><description><![CDATA[There are n cities connected by m flights. Each fight starts from city u and arrives at v with a price w.
Now given all the cities and flights, together with starting city src and the destination dst,...]]></description><category></category></item><item><title><![CDATA[KMP算法：两个字符串的匹配，S1里匹配S2]]></title><link>https://blog.youkuaiyun.com/katrina95/article/details/102036463</link><guid>https://blog.youkuaiyun.com/katrina95/article/details/102036463</guid><author>katrina95</author><pubDate>Fri, 04 Oct 2019 02:18:29 +0800</pubDate><description><![CDATA[通过创建一个部分匹配表来优化指针后移的效率。
http://www.ruanyifeng.com/blog/2013/05/Knuth%E2%80%93Morris%E2%80%93Pratt_algorithm.html

]]></description><category></category></item><item><title><![CDATA[647. Palindromic Substrings(java)]]></title><link>https://blog.youkuaiyun.com/katrina95/article/details/101969667</link><guid>https://blog.youkuaiyun.com/katrina95/article/details/101969667</guid><author>katrina95</author><pubDate>Thu, 03 Oct 2019 06:55:10 +0800</pubDate><description><![CDATA[Given a string, your task is to count how many palindromic substrings in this string.
The substrings with different start indexes or end indexes are counted as different substrings even they consist o...]]></description><category></category></item><item><title><![CDATA[685. Redundant Connection II(java)]]></title><link>https://blog.youkuaiyun.com/katrina95/article/details/101966697</link><guid>https://blog.youkuaiyun.com/katrina95/article/details/101966697</guid><author>katrina95</author><pubDate>Thu, 03 Oct 2019 05:37:16 +0800</pubDate><description><![CDATA[In this problem, a rooted tree is a directed graph such that, there is exactly one node (the root) for which all other nodes are descendants of this node, plus every node has exactly one parent, excep...]]></description><category></category></item><item><title><![CDATA[684. Redundant Connection(java)]]></title><link>https://blog.youkuaiyun.com/katrina95/article/details/101957354</link><guid>https://blog.youkuaiyun.com/katrina95/article/details/101957354</guid><author>katrina95</author><pubDate>Thu, 03 Oct 2019 02:15:51 +0800</pubDate><description><![CDATA[In this problem, a tree is an undirected graph that is connected and has no cycles.
The given input is a graph that started as a tree with N nodes (with distinct values 1, 2, …, N), with one additiona...]]></description><category></category></item><item><title><![CDATA[355. Design Twitter]]></title><link>https://blog.youkuaiyun.com/katrina95/article/details/101419996</link><guid>https://blog.youkuaiyun.com/katrina95/article/details/101419996</guid><author>katrina95</author><pubDate>Thu, 26 Sep 2019 08:41:17 +0800</pubDate><description><![CDATA[Design a simplified version of Twitter where users can post tweets, follow/unfollow another user and is able to see the 10 most recent tweets in the user’s news feed. Your design should support the fo...]]></description><category></category></item><item><title><![CDATA[约瑟夫环]]></title><link>https://blog.youkuaiyun.com/katrina95/article/details/101412911</link><guid>https://blog.youkuaiyun.com/katrina95/article/details/101412911</guid><author>katrina95</author><pubDate>Thu, 26 Sep 2019 05:34:18 +0800</pubDate><description><![CDATA[约瑟夫问题
约瑟夫问题是个著名的问题：N个人围成一圈，第一个人从1开始报数，报M的将被杀掉，下一个人接着从1开始报。如此反复，最后剩下一个，求最后的胜利者。
例如只有三个人，把他们叫做A、B、C，他们围成一圈，从A开始报数，假设报2的人被杀掉。
首先A开始报数，他报1。侥幸逃过一劫。
然后轮到B报数，他报2。非常惨，他被杀了
C接着从1开始报数
接着轮到A报数，他报2。也被杀死了。
最终胜利者是C...]]></description><category></category></item><item><title><![CDATA[390. Elimination Game（约瑟夫环）]]></title><link>https://blog.youkuaiyun.com/katrina95/article/details/101412669</link><guid>https://blog.youkuaiyun.com/katrina95/article/details/101412669</guid><author>katrina95</author><pubDate>Thu, 26 Sep 2019 05:31:02 +0800</pubDate><description><![CDATA[There is a list of sorted integers from 1 to n. Starting from left to right, remove the first number and every other number afterward until you reach the end of the list.
Repeat the previous step agai...]]></description><category></category></item><item><title><![CDATA[60. Permutation Sequence]]></title><link>https://blog.youkuaiyun.com/katrina95/article/details/101352588</link><guid>https://blog.youkuaiyun.com/katrina95/article/details/101352588</guid><author>katrina95</author><pubDate>Wed, 25 Sep 2019 11:23:17 +0800</pubDate><description><![CDATA[The set [1,2,3,…,n] contains a total of n! unique permutations.
By listing and labeling all of the permutations in order, we get the following sequence for n = 3:
“123”
“132”
“213”
“231”
“312”
“321”
G...]]></description><category></category></item><item><title><![CDATA[381. Insert Delete GetRandom O(1) - Duplicates allowed]]></title><link>https://blog.youkuaiyun.com/katrina95/article/details/101335611</link><guid>https://blog.youkuaiyun.com/katrina95/article/details/101335611</guid><author>katrina95</author><pubDate>Wed, 25 Sep 2019 05:14:02 +0800</pubDate><description><![CDATA[Design a data structure that supports all following operations in average O(1) time.
Note: Duplicate elements are allowed.
insert(val): Inserts an item val to the collection.
remove(val): Removes an i...]]></description><category></category></item><item><title><![CDATA[23. Merge k Sorted Lists]]></title><link>https://blog.youkuaiyun.com/katrina95/article/details/101328554</link><guid>https://blog.youkuaiyun.com/katrina95/article/details/101328554</guid><author>katrina95</author><pubDate>Wed, 25 Sep 2019 02:32:09 +0800</pubDate><description><![CDATA[Merge k sorted linked lists and return it as one sorted list. Analyze and describe its complexity.
Example:

Input:
[
  1-&gt;4-&gt;5,
  1-&gt;3-&gt;4,
  2-&gt;6
]
Output: 1-&gt;1-&gt;2-&gt;3-&gt;4-&g...]]></description><category></category></item><item><title><![CDATA[146. LRU Cache]]></title><link>https://blog.youkuaiyun.com/katrina95/article/details/101286909</link><guid>https://blog.youkuaiyun.com/katrina95/article/details/101286909</guid><author>katrina95</author><pubDate>Tue, 24 Sep 2019 15:20:02 +0800</pubDate><description><![CDATA[Design and implement a data structure for Least Recently Used (LRU) cache. It should support the following operations: get and put.
get(key) - Get the value (will always be positive) of the key if the...]]></description><category></category></item><item><title><![CDATA[380. Insert Delete GetRandom O(1)]]></title><link>https://blog.youkuaiyun.com/katrina95/article/details/101281548</link><guid>https://blog.youkuaiyun.com/katrina95/article/details/101281548</guid><author>katrina95</author><pubDate>Tue, 24 Sep 2019 14:02:43 +0800</pubDate><description><![CDATA[Design a data structure that supports all following operations in average O(1) time.
insert(val): Inserts an item val to the set if not already present.
remove(val): Removes an item val from the set i...]]></description><category></category></item><item><title><![CDATA[432. All O`one Data Structure（java）]]></title><link>https://blog.youkuaiyun.com/katrina95/article/details/101277522</link><guid>https://blog.youkuaiyun.com/katrina95/article/details/101277522</guid><author>katrina95</author><pubDate>Tue, 24 Sep 2019 12:55:12 +0800</pubDate><description><![CDATA[Implement a data structure supporting the following operations:
Inc(Key) - Inserts a new key with value 1. Or increments an existing key by 1. Key is guaranteed to be a non-empty string.
Dec(Key) - If...]]></description><category></category></item><item><title><![CDATA[二进制作为hashset存放visited,获取和设置第n位的值]]></title><link>https://blog.youkuaiyun.com/katrina95/article/details/100695848</link><guid>https://blog.youkuaiyun.com/katrina95/article/details/100695848</guid><author>katrina95</author><pubDate>Tue, 10 Sep 2019 13:03:18 +0800</pubDate><description><![CDATA[获取x第n位的值：（x&gt;&gt;n） &amp; 1
设置x第n位的值为1：x = x || 1&lt;&lt;n

]]></description><category></category></item><item><title><![CDATA[53. Maximum Subarray(写1186顺便复习一下这道题的两种写法)]]></title><link>https://blog.youkuaiyun.com/katrina95/article/details/100659519</link><guid>https://blog.youkuaiyun.com/katrina95/article/details/100659519</guid><author>katrina95</author><pubDate>Mon, 09 Sep 2019 13:39:02 +0800</pubDate><description><![CDATA[Given an integer array nums, find the contiguous subarray (containing at least one number) which has the largest sum and return its sum.
Example:

Input: [-2,1,-3,4,-1,2,1,-5,4],
Output: 6
Explanation...]]></description><category></category></item><item><title><![CDATA[LeetCode 1186. Maximum Subarray Sum with One Deletion(java)]]></title><link>https://blog.youkuaiyun.com/katrina95/article/details/100659406</link><guid>https://blog.youkuaiyun.com/katrina95/article/details/100659406</guid><author>katrina95</author><pubDate>Mon, 09 Sep 2019 13:35:57 +0800</pubDate><description><![CDATA[Given an array of integers, return the maximum sum for a non-empty subarray (contiguous elements) with at most one element deletion. In other words, you want to choose a subarray and optionally delete...]]></description><category></category></item><item><title><![CDATA[LeetCode 815. Bus Routes(java)]]></title><link>https://blog.youkuaiyun.com/katrina95/article/details/100652103</link><guid>https://blog.youkuaiyun.com/katrina95/article/details/100652103</guid><author>katrina95</author><pubDate>Mon, 09 Sep 2019 09:34:47 +0800</pubDate><description><![CDATA[We have a list of bus routes. Each routes[i] is a bus route that the i-th bus repeats forever. For example if routes[0] = [1, 5, 7], this means that the first bus (0-th indexed) travels in the sequenc...]]></description><category></category></item></channel></rss>