Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 2

1. Define the terms; data structures, data types & abstract data types.

Data Structures
A data structure is simply some way of organizing a value that consists
of multiple parts; or a representation of data and the operations allowed
on that data.
A data structure is a group of data elements grouped together under one
name. These data elements, known as members, can have different types
and different lengths.
Data Types
A data type is characterized by: a set of values , a data representation,
which is common to all these values, and a set of operations, which can be
applied uniformly to all these values
A data type is a classification identifying one of various types of data,
such as real-valued, integer or Boolean, that determines the possible
values for that type; the operations that can be done on values of that type;
the meaning of the data; and the way values of that type can be stored.
Abstract Data Types
An abstract data type (ADT) is a mathematical model for a certain class
of data structures that have similar behavior; or for certain data types of
one or more programming languages that have similar semantics.
An Abstract Data Type (ADT) is: a set of values or a set of operations,
which can be applied uniformly to all these values; Abstract Data Types
(ADTs) or data structures or collections store data and allow various
operations on the data to access and change it.

2. Define what an Algorithm is

An algorithm is a specific set of instructions for carrying out a procedure or


solving a problem, usually with the requirement that the procedure terminate at
some point. Specific algorithms sometimes also go by the
name method, procedure, or technique.
A step-by-step problem solving procedure, especially an established recursive
computational procedure for solving a problem in a finite number of steps. It is a
finite sequence of steps for solving a logical or mathematical problem.

3. Describe the Criteria for creating a Good Algorithm

Criteria for a Good Algorithm

A. Specify each step or instructions exactly. There must be no ambiguity. The


instructions must be clear.
B. There must be a finite number of steps. The algorithm must terminate.
There must be a stopping point.
C. There must be an output. The algorithm must produce the correct result.
4. Differentiate Pseudocode from Algorithm

An Algorithm is a specific set of well-defined, simple mathematical and logical


procedures that can be followed to solved a problem in a finite number of steps
while Pseudocode is a generic way of describing an algorithm without use of any
specific programming language syntax. It cannot be executed on a real computer,
but it models and resembles real programming code, and is written at roughly the
same level detail.

5. Describe the Analysis of Algorithm


Analysis of Algorithms (AofA) is a field at the boundary of computer science
and mathematics. The goal is to obtain a precise understanding of the asymptotic,
average-case characteristics of algorithms and data structures. A unifying theme is the use
of probabilistic, combinatorial, and analytic methods. The objects to be studied include
random branching processes, graphs, permutations, trees, and strings.
The analysis of algorithms is the determination of the amount of resources (such
as time and storage) necessary to execute them. Most algorithms are designed to work
with inputs of arbitrary length. Usually the efficiency or running time of an algorithm is
stated as a function relating the input length to the number of steps (time complexity) or
storage locations (space complexity).
Algorithm analysis is an important part of a broader computational complexity
theory, which provides theoretical estimates for the resources needed by any algorithm
which solves a given computational problem. These estimates provide an insight into
reasonable directions of search for efficient algorithms.

You might also like