Skip to content

Commit 5bcdc67

Browse files
committed
readme update
1 parent c94d159 commit 5bcdc67

File tree

1 file changed

+31
-1
lines changed

1 file changed

+31
-1
lines changed

README.md

Lines changed: 31 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,4 +176,34 @@ Hint: Try preprocessing the dictionary into a more efficient data structure to s
176176
### Solution
177177
[JS](pb11/answer.js) (1:28)
178178

179-
[Python](pb11/answer.py)
179+
[Python](pb11/answer.py)
180+
181+
---
182+
183+
## 12
184+
> This problem was asked by Amazon.
185+
186+
There exists a staircase with N steps, and you can climb up either 1 or 2 steps at a time. Given N, write a function that returns the number of unique ways you can climb the staircase. The order of the steps matters.
187+
For example, if N is 4, then there are 5 unique ways:
188+
```
189+
1, 1, 1, 1
190+
2, 1, 1
191+
1, 2, 1
192+
1, 1, 2
193+
2, 2
194+
```
195+
What if, instead of being able to climb 1 or 2 steps at a time, you could climb any number from a set of positive integers X? For example, if `X = {1, 3, 5}`, you could climb 1, 3, or 5 steps at a time.
196+
197+
### Solution
198+
[JS](pb12/answer.js) (Partial solution only)
199+
200+
---
201+
202+
## 13
203+
> This problem was asked by Amazon.
204+
205+
Given an integer k and a string s, find the length of the longest substring that contains at most k distinct characters.
206+
For example, given s = "abcba" and k = 2, the longest substring with k distinct characters is "bcb".
207+
208+
### Solution
209+
[JS](pb13/answer.js) (10:47)

0 commit comments

Comments
 (0)