From b649fe019c0f46d979bf0f818561a986ca41b54d Mon Sep 17 00:00:00 2001 From: Jerome Pui Date: Sat, 4 Jun 2022 01:22:00 +0800 Subject: [PATCH] contents: fix typo and grammar in study cheatsheet (#279) --- contents/algorithms/study-cheatsheet.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contents/algorithms/study-cheatsheet.md b/contents/algorithms/study-cheatsheet.md index 9d8d14f5..7dc8010e 100644 --- a/contents/algorithms/study-cheatsheet.md +++ b/contents/algorithms/study-cheatsheet.md @@ -84,7 +84,7 @@ Data structures are your weapons. Choosing the right weapon for the right battle Data structures can be augmented to achieve efficient time complexities across different operations. For example, a hash map can be used together with a doubly-linked list to achieve O(1) time complexity for both the `get` and `put` operation in an [LRU cache](https://leetcode.com/problems/lru-cache/). -hash tables are probably the most commonly used data structure for algorithm questions. If you are stuck on a question, your last resort can be to enumerate through the common possible data structures (thankfully there aren't that many of them) and consider whether each of them can be applied to the problem. This has worked for me sometimes. +Hash table is probably the most commonly used data structure for algorithm questions. If you are stuck on a question, your last resort can be to enumerate through the common possible data structures (thankfully there aren't that many of them) and consider whether each of them can be applied to the problem. This has worked for me sometimes. If you are cutting corners in your code, state that out loud to your interviewer and say what you would do in a non-interview setting (no time constraints). E.g., I would write a regex to parse this string rather than using `split()` which may not cover all cases.