Documente Academic
Documente Profesional
Documente Cultură
Q1. Demonstrate the concept of Top down approach and bottom up approach in any
software project.
Ans: - Top Down Design: - Top Down design is also known as functional decomposition or
step refinement. It has following steps: -
Describe a problem in terms of high level sub-problems.
Describe each in terms of simpler sub-sub-problems.
Continue the breakdown until the subtasks are sufficiently simple to be implemented
directly.
A B C E
Data
D
F
G Data derived
from relationships
I
H
J Conclusions
Top Level
Parse Dispatch
command command
Bottom Up approach: - A bottom up approach starts with designing the most basic
components and proceeds to higher level components that use these lower level components.
Bottom up methods work with the layers of abstraction. A bottom up approach is the reverse
process where the lowest level components are built first and the system builds up from the
bottom until the process is finally completed.
Collect from libraries or create working modules for low-level tasks.
Continue this collection of modules until sufficient are found to solve the problem.
Integrate the modules into an overall structure.
Data E
A B C D
G
F
Required data due
To relationships
I
H
J
Conclusions
Figure 9: Top- down Approach
Q2. Identify all the components of data flow diagrams first and then implement few of
those in developing DFD for your software project.
Ans: - A DFD is a graphical representation of the “flow” of the data through an information
system. The DFD is a hierarchical graphical model of a system that shows the different
processing activities that the system performs. The main components of data flow diagram
are as follows: -
In the library information system, the user may request for a book. The book is searched
according to the title and author of the book. When the book is found it is given to the used
and the list of the borrowed books are maintained and it is displayed.
Q3. Demonstrate the concept of coupling and cohesion for any software project.
Ans: - Coupling: - Coupling between modules is the strength of interconnections between
modules or a measure of interdependence among modules. “Highly coupled” modules have
strong interconnection among the modules while “Loosely coupled” modules have weak
interconnection among modules. Independent modules have no interconnections. The
coupling between modules is decided during system design and cannot be reduced during
implementation.
Coupling increases with the complexity between modules. To keep
coupling low we would like to minimize the number of interfaces per module and complexity
of each interface. An interface of a module is used to pass information to and from other
modules. Coupling is reduced if only the defined entry interface of a module is used by other
modules. Coupling would increase if a module is used by other modules via an indirect and
obscure information, like directly using the internals of a module or using shared variables.
Complexity of the interface is another factor affecting coupling. The
more complex each interface is, the higher will be the degree of coupling.
Cohesion: - Cohesion of a module represents how tightly bound the internal elements of the
module are to one another. Cohesion of a module gives the designer an idea about whether
the different elements of a module belong together in the same module. Cohesion and
coupling are clearly related. The greater the cohesion of each module in the system, the lower
the coupling between modules is. There are several levels of cohesion:
Coincidental
Logical
Temporal
Procedural
Communicational
Sequential
Functional
Coincidental is the lowest level and functional is the highest. These levels do not form a
linear scale.
Coincidental Cohesion occurs when there is no meaningful relationship among the
elements of a module. Coincidental cohesion can occur if an existing program is
“modularized” by divide it into pieces and different pieces modules.
Logical Cohesion occurs if there is some logical relationship between the elements of a
module, and the elements perform functions that fall in the same logical class. A typical
example of this type of cohesion is a module that performs all the inputs or all the
outputs.
Temporal Cohesion is the same as logical cohesion, except that the elements are also
related in time and are executed together. Modules that perform activities like
“initialization”, “clean-up” and “terminator” are usually temporally bound.
Procedural Cohesion module contains elements that belong to a common procedural
unit. For example, a loop or a sequence of decision statements in a module may be
combined to form a separate module.
Communicational Cohesion has elements that are related by a reference to the same
input or output data. In a communicationally bound module, the elements are together
because they operate on the same input or output data.
Sequential Cohesion is that when the elements are together in a module because the
output of one forms the input to another. If we have a sequence of elements in which the
output of one forms the input to another.
Functional Cohesion is the strongest cohesion. In a functionally bound module, all the
elements of the module are related to performing a single function.
PART B
Q1. As a debugger how will you identify different errors in software project? Suggest
some techniques to avoid errors during coding.
Ans: - Errors are the obstacles that stop the process to execute in a proper manner. These are
the common part of any project. As a debugger the errors can be identified in the following
conditions: -
Brute Force Method: - This is the most common method of debugging but is
the least efficient method. In this approach the program is loaded with print
statements to print the intermediate values with hope that the printed value
will help in identifying the errors.
Backtracking: - In this approach beginning from the statement at which
errors symptoms have been observed the source code is traced backward until
the error is discovered. The number of lines to be traced back increases.
Cause of elimination Method: - In this approach a list of cause which could
have contributed to the error system is developed and the tests are conducted
to eliminate each.
Q3. How will you flow particular information in your company when number of
persons are working on different responsibilities and levels?
Ans: - The information in a company is flowed from top to bottom. The person at the top
sends information to all its lowest level persons whether they are working on the same level
or different levels.
Top Down Flow of information
When the information is sent in a company, the persons at the highest level send information
to their lowest level then the information is sent to next lowest level. In this way, the
information is sent to the last level in a company.
Top level
1st level
2nd level
Lowest level
In this flow of information, the information is sent from the top level to the lowest level in a company.
The information is sent to all the persons who are working in an organization at different levels and
different responsibilities.