Home|Contents|Prev|Next|Chat


DAA Answers 10 - 28 two-mark answers

  1. Need to study algorithms: know standard algorithms and analyse efficiency; cornerstone of CS.
  2. Algorithmics: the study of algorithms; the core of computer science.
  3. Algorithm: unambiguous instructions; required output for any legitimate input in finite time.
  4. Notion diagram: problem -> [algorithm] -> answer.
  5. Euclid formula: gcd(m,n)=gcd(n,m mod n) until 0; gcd(m,0)=m.
  6. Three gcd methods: Euclid, consecutive integer, middle-school.
  7. Problem solving: understand, device, exact/approx, structures, technique, specify, prove, analyse, code.
  8. Design technique: a general approach applicable to many problems.
  9. Pseudocode: natural language + programming constructs, more precise/concise.
  10. Efficiency types: time and space.
  11. Problem types: sorting, searching, string, graph, combinatorial, geometric, numerical.
  12. Geometric problems: closest-pair, convex-hull.
  13. Analysis steps: input size, units, orders of growth, best/worst/average.
  14. Basic operation: most time-consuming op, usually innermost loop.
  15. Running time: T(n) ~ cop x C(n).
  16. Exponential growth: 2^n, n!.
  17. Worst case: input for which the algorithm runs longest.
  18. Best case: input for which it runs fastest.
  19. Average case: typical/random input; not the mean of best and worst.
  20. Amortized: n operations cost much less than n x worst-case of one.
  21. O: t(n)<=c.g(n) for n>=n0.
  22. Omega: t(n)>=c.g(n) for n>=n0.
  23. Theta: c1.g(n)<=t(n)<=c2.g(n) for n>=n0.
  24. Useful property: O(g1)+O(g2)=O(max{g1,g2}).
  25. Efficiency classes: 1, log n, n, n log n, n^2, n^3, 2^n, n!.
  26. Algorithm visualization: images conveying operation, performance, speed.
  27. Two variations: static and dynamic (animation).
  28. Order of growth: performance as a function of input size n.

Home|Contents|Prev|Next|Top|Chat