CSC Assignment Question 1
CSC Assignment Question 1
ii.) Sequential Programming is a programming model that is based on the concept of a single
thread of execution. This means that each instruction must complete before the next instruction
can be executed.
bi). Problem Analysis: This is the initial stage where the programmer identifies the problem,
understands the requirements, and analyzes the problem domain. This involves breaking down
the problem into smaller components and identifying the data and operations needed.
bi). Algorithm Design: In this phase, the programmer designs the high-level solution to the
problem using algorithms. This involves determining the logical steps and sequence of
operations required to solve the problem.
biii). Implementation: In this stage, the programmer translates the algorithm into a
programming language by writing the code. This involves writing the specific instructions using
the chosen programming language syntax.
biv). Testing and Debugging: Once the code is written, it needs to be tested to ensure it works
as intended. Test cases are created to verify that the program produces the expected results. If
errors or bugs are found, they are debugged and fixed.
bv). Maintenance and Optimization: After the program is successfully implemented and tested,
it may require maintenance and optimization. This phase includes making updates or
modifications to the code, improving efficiency, and fixing any issues that may arise during
usage.
C). In sequential programming, instructions are executed in a linear and sequential order, one
after another. It follows a single-threaded execution model where only one instruction is
executed at a time. This means that the program flow is determined by the order of instructions
and each instruction must complete before the next one can be executed While Concurrent
programming, on the other hand, involves the simultaneous execution of multiple tasks or
processes. It follows a multi-threaded execution model where multiple threads can be executed
concurrently. These threads can execute independently and asynchronously, allowing for
parallel processing and utilization of multiple resources. This allows for better performance and
efficiency in handling complex and time-sensitive tasks.