Back
To Course Outline - COSI335
Chapter One: The Role of Algorithms
in Computing
What are algorithms?
-
An algorithm is a sequence of computational steps that transform
the input into the output.
-
The algorithm describes a specific computational
procedure for achieving that input/output relationship.
-
It is like a recipe that you can follow
and solve problems.
The objectives of this course:
-
Understanding how to design an algorithm.
-
Understanding how to evaluate an algorithm
(running time from either math or programming to estimate ).
-
Having a strategy to come out a solution.
Example: Guess the number (integer) between 1 and 100.
What is a strategy for the least number of questions you need to ask?
You may take 6 or 7 questions to get the answer for this problem, by
(Time
<= log2100)
Binary Search: (find mid-points)
Click here to see the detail.
-
Using JAVA or C++ or other languages to run
your algorithm.