-
Notifications
You must be signed in to change notification settings - Fork 75
Expand file tree
/
Copy pathchapterGeneral.tex
More file actions
9 lines (9 loc) · 892 Bytes
/
chapterGeneral.tex
File metadata and controls
9 lines (9 loc) · 892 Bytes
1
2
3
4
5
6
7
8
9
% !TEX root = algo-quicksheet.tex
\chapter{General}
\section{General Tips}
\runinhead{Information Source.} Keep the source information rather than derived information (e.g. keep the array index rather than array element).
\runinhead{Information Transformation.} Need you keep the raw information to avoid information loss (e.g. after converting \pyinline{str} to \pyinline{list}, you should keep \pyinline{str}).
\runinhead{Element Data Structure} When working with ADT, you should use a more intelligence data structure as type to avoid allocating another ADT to maintain the state (e.g. \javainline{java.util.PriorityQueue<E>}).
\runinhead{Solving unseen problems.} Solving unseen problems is like a search problems. You need to explore different options, either with dfs or bfs.
\runinhead{Small samples.} Try out with some small input sample.
\runinhead{Corner cases.} Atypical input.