Preview

01 - Introduction to Algorithms

 1. You could think of an algorithm as a ____________________ that are necessary to follow in order to solve a problem.

  series of combined brains

  series of steps

  series of problems

  program code

 2. The word algorithm itself derives from the 9th Century mathematician Muhammad bin Musa al-Khwarizmi

  False

  True

 3. In computer science, an algorithm is devised to help a programmer or computer accomplish a certain task. A _____ or pseudocode can be used to devise an algorithm.

  sequence of binary numbers

  hexadecimal hash tag

  line of ASCII code

  flowchart

 4. Babylonian clay tablets described and employed algorithmic procedures to compute the time and place of significant astronomical events.
Image source: https://scientificgems.wordpress.com
babylonian_clay_tablet_algorithm.png

  FALSE

  TRUE

 5. Interesting trivia question: How does Google Hangouts transmit live video across the Internet so quickly? And how does Google Maps figure out a route from x to y?

  Google does not use algorithms for this, as it is isn't algorithmic in nature

  Google uses Big O notation to accomplish both these things

  Video compression algorithm / route finding algorithm

  Google uses a single algorithm to accomplish every task (including video streaming and path finding)

 6. Not all algorithms are created equal - so which of the following is important for making a 'good' algorithm?
1. The algorithm should solve the problem
2. The algorithm should solve the problem efficiently
3. The algorithm should take up the maximum amount of resources
4. The algorithm should take up minimal (ideally) resources
5. The algorithm should be as slow and precise as possible
6. The algorithm should be both precise and as fast as possible

  4 and 5 only

  1 and 5 only

  1,2,4 and 6

  1,2 and 5 only

 7. In Computer science ____________________ is used to handle the issues that arise in analysing and comparing algorithms.

  the starred algorithm

  karnuah mapping

  boolean logic

  asymptotic analysis

 8. In Asymptotic Analysis, we evaluate the performance of an algorithm in terms of _____________ (we don’t measure the actual running time).
Note: We calculate, how does the time (or space) taken by an algorithm increases with the input size.

  input size

  the length of the code

  the x and y coordinates

  output

 9. Read the categorisation of algorithms below and fill in the blanks for the third category.
Usually, the time required by an algorithm falls under three types ?

Best Case ? Minimum time required for program execution.

Average Case ? Average time required for program execution.

____________???? Maximum time required for program execution.

  Scale case

  Lowest case

  Zero case

  Worst case

 10. Because an algorithm is a precise list of precise steps, the ____ of computation is always crucial to the functioning of the algorithm

  input

  code

  output

  order

 11. Algorithms can be expressed in many kinds of notation, including natural languages, pseudocode, flowcharts, drakon-charts, programming languages or control tables

  FALSE

  TRUE

 12. One of the most important aspects of algorithm design is creating an algorithm that has an efficient run-time, also known as its _____

  Big N notation

  scale time

  finite O

  Big O

 13. Decide whether the following excerpt on algorithms is true or false
Most algorithms are intended to be implemented as computer programs. 
However, algorithms are also implemented by other means, such as in a 
biological neural network (for example, the human brain implementing 
arithmetic or an insect looking for food), in an electrical circuit, 
or in a mechanical device

  TRUE

  FALSE

 14. ___________may be used to compare before/after potential improvements to an algorithm after program optimization

  CPU markers

  Algobrains

  Benchmarks

  Hallmarks

 15. This refers to the amount of data that the algorithm will manipulate.

  input size

  intractable

  output size

  minimal size

 16. Some problems cannot be solved in a time which is practical with current processing power and they are called ________ problems.

  intractable

  miniscual

  feasible

  finite

 17. This is a problem that tries to identify whether a program will eventually halt or whether it will run forever.

  turing complete problem

  artificial intelligence problem

  halting problem

  humanoid spirituality problem

 18. In any given problem, as the input size increases, there will be more resources required in terms of processor power and storage. This means:

  the processing time could decrease, with the input size, as this is usually what occurs in these scenarios

  the processing time could grow exponentially depending on the time complexity of the algorithm

  the processing time could remain exactly the same, regardless of the input

  the processing time could be reduced drastically and therefore solve the problem

 19. Many applications are _________ which means that they have to react instantly. Any delay caused by an inefficient algorithm could prevent the system from working properly

  virtual reaction algorithms

  scale critical

  time critical

  delay critical

 20. BigO is, simply put, a measure of ___________________. In a best case scenario, even the worst algorithm may be finished in one operation/iteration

  time and scalability

  algorithm complexity

  time input collation

  output delay