Problem Solving with Algorithms: A Guide for Trainee Software Developers, Assignments of Programming Languages

You have applied for a post as a trainee with a software development company and have been invited for an interview. You have been asked to demonstrate your problem solving and basic programming skills. To do this you have to prepare a report on using algorithms to solve problems. You need to explain, using examples, how algorithms are used to solve simple business problems and the steps needed to be followed to produce a working program solution.

Typology: Assignments

2020/2021

Uploaded on 06/15/2022

ng-n-minh-anh
ng-n-minh-anh 🇻🇳

4.8

(26)

34 documents

1 / 17

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
Higher Nationals in Computing
Unit 1: Programming
ASSIGNMENT 1
Learner’s name: NGUYEN NHAT MINHANH
ID: GCS200658
Class: GCS0905C
Subject code: 1618
Assessor name: PHAN MINH TAM
Assignment due: Assignment submitted:
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff

Partial preview of the text

Download Problem Solving with Algorithms: A Guide for Trainee Software Developers and more Assignments Programming Languages in PDF only on Docsity!

Higher Nationals in Computing

Unit 1: Programming

ASSIGNMENT 1

Learner’s name: NGUYEN NHAT MINH ANH

ID: GCS

Class: GCS0905C

Subject code: 1618

Assessor name: PHAN MINH TAM

Assignment due: Assignment submitted:

ASSIGNMENT 1 FRONT SHEET

Qualification BTEC Level 5 HND Diploma in Computing

Unit number and title Unit 1: Programming

Submission date October 3

rd

, 2021 Date Received 1st submission

Re-submission Date Date Received 2nd submission

Student Name

NGUYEN NHAT MINH ANH

Student ID

GCS

Class GCS0905C Assessor name Phan Minh Tam

Student declaration

I certify that the assignment submission is entirely my own work and I fully understand the consequences of plagiarism. I understand that

making a false declaration is a form of malpractice.

Student’s signature

Grading grid

P1 M1 D

Assignment Brief 1 (RQF)

Higher National Certificate/Diploma in Computing

Student Name/ID Number:

Unit Number and Title: Unit 1: Programming

Academic Year: 2021 – 2022

Unit Assessor: Phan Minh Tam

Assignment Title: Problem solving with algorithms

Issue Date: 27 September 2021

Submission Date:

Internal Verifier Name:

Date:

Submission Format:

Format:

● The submission is in the form of an individual written report. This should be written in a concise,

formal business style using single spacing and font size 12. You are required to make use of

headings, paragraphs and subsections as appropriate, and all work must be supported with

research and referenced using the Harvard referencing system. Please also provide a bibliography

using the Harvard referencing system.

Submission

● Students are compulsory to submit the assignment in due date and in a way requested by the

Tutor.

● The form of submission will be a soft copy posted on http://cms.greenwich.edu.vn/.

● Remember to convert the word file into PDF file before the submission on CMS.

Note:

● The individual Assignment must be your own work, and not copied by or from another student.

● If you use ideas, quotes or data (such as diagrams) from books, journals or other sources, you

must reference your sources, using the Harvard style.

● Make sure that you understand and follow the guidelines to avoid plagiarism. Failure to comply

this requirement will result in a failed assignment.

Unit Learning Outcomes:

LO1 Define basic algorithms to carry out an operation and outline the process of programming an

application

Assignment Brief and Guidance:

Assignment scenario

You have applied for a post as a trainee with a software development company and have been invited

for an interview. You have been asked to demonstrate your problem solving and basic programming

skills. To do this you have to prepare a report on using algorithms to solve problems.

You need to explain, using examples, how algorithms are used to solve simple business problems and

the steps needed to be followed to produce a working program solution. You should make clear your

assumption about your program. The problems to be solved will involve basic procedural programming

instructions - sequence instructions (input, output and assignment statements), loops, conditional

statements. Problems should be analysed and designed by the use of flowchart and demonstrated by

the use of modules (procedures).

Tasks:

 State your simple business problems to be solved.

 Analyse the problem and design the solutions by the use of suitable methods.

 Demonstrate the compilation and running of a program

 Evaluate how the problem is solved from the designed algorithm to the execution program

written by a specific programming language.

Learning Outcomes and Assessment Criteria

Pass Merit Distinction

LO1 Define basic algorithms to carry out an operation and outline the process of programming an

application

P1 Provide a definition of what

an algorithm is and outline the

process in building an

application.

M1 Determine the steps taken from

writing code to execution.

D1 Examine the implementation

of an algorithm in a suitable

language. Evaluate the

relationship between the written

algorithm and the code variant.

P1. Algorithm

1. Definition of algorithm and characteristics of the algorithm.

1.1. Definition of algorithm

1.2. Characteristics of algorithm.

1.3 Types of Algorithms

1.4 Example of an Algorithm

1.5 Is the algorithm important?

2. Software Development Life Cycle (SDLC)

2.1 Requirement Gathering and Analysis

2.2 Design..................................................................................................................................... 7

2.3 Implementation or Coding.................................................................................................... 8

2.4 Testing.................................................................................................................................... 8

2.5 Deployment........................................................................................................................... 8

2.6 Maintenance.......................................................................................................................... 9

REFERENCES.............................................................................................................................................. 10

Table of Contents

P a g e | 1

ASSIGNMENT 1 ANSWERS

P1. Algorithm

1. Definition of algorithm and characteristics of the algorithm.

1.1. Definition of algorithm

 Algorithms are a fundamental concept of Mathematics and Informatics. In simple terms, an

algorithm is a set of instructions to perform a certain task.

 An algorithm is a step-by-step method of solving a class of problems.

 It is a well-defined process that enables a computer to solve a mathematical or problem problem.

Algorithms are capable of performing tasks such as computation, data processing, and automated

reasoning.

P a g e | 3

Ex : X →1. Toss a coin, if result is head then X → 3 else x→4. In the above program, all the steps

would be carried out effectively but there is no definiteness since there are two possible

values of X 1 and ¾.

Inputs : An algorithm must have zero or more inputs, but they must be finite. A zero-input

algorithm in action. Print the ASCII code of each of the letter in the alphabet of computer system.

Output : An algorithm must have at-least one desirable outcome

Effectiveness : An algorithm should be effective. Effective means that each step should be referred

as principle and should be executing in finite time.

Ex : Cook perfectly fluffy rice.z

1.3 Types of Algorithms

Algorithms are categorized according to the concepts they employ to complete a task. While there are

many other types of algorithms, the following are the most common ones in computer science:

Divide and conquer algorithms : divide the problem into smaller subproblems of the same type;

solve those smaller problems, and combine those solutions to solve the original problem.

Brute force algorithms : try all possible solutions until a satisfactory solution is found.

Randomized algorithms : use a random number at least once during the computation to find a

solution to the problem.

P a g e | 4

Greedy algorithms : find an optimal solution at the local level with the intent of finding an optimal

solution for the whole problem.

Recursive algorithms : solve the lowest and simplest version of a problem to then solve

increasingly larger versions of the problem until the solution to the original problem is found.

Backtracking algorithms : divide the problem into subproblems, each which can be attempted to

be solved; however, if the desired solution is not reached, move backwards in the problem until a

path is found that moves it forward.

Dynamic programming algorithms: break a complex problem into a collection of simpler

subproblems, then solve each of those subproblems only once, storing their solution for future

use instead of re-computing their solutions.

1.4 Example of an Algorithm

For solving a Rubik's cube, there are a variety of methods available, ranging from basic to complex.

Here's a simple algorithm that cuts the time it takes to answer this well-known puzzle in half. Let's

start by deciding on a notation to utilize (similar to picking a programming language). A Rubik's cube's

six faces may be represented by the first letter of their names: U - up, D - down, L - left, R - right, F -

front, B - back.

P a g e | 6

2. Software Development Life Cycle (SDLC)

The Software Development Life Cycle (SDLC)

refers to a methodology with clearly defined

processes for creating high-quality software. in

detail, the SDLC methodology focuses on the

following phases of software development:

2.1 Requirement Gathering and Analysis

A software requirement is a capability needed by the user to solve a problem or to achieve an

objective. In other words, requirement is a software capability that must be met or possessed by a

system or system component to satisfy a contract, standard, specification, or other formally

imposed documentation. Ultimately, what we want to achieve is to develop quality software that

meets customers' real needs on time and within budget.

P a g e | 7

2.2 Design

The software architecture for system development is created using the requirements gathered in the

SRS document as input.

P a g e | 9

testing phase, the product is ready to go live. This means that the product is ready to be used in a

real environment by all end users of the product.

 There are various phases of the deployment process the project team must follow to ensure the

code and technology deploy appropriately. The phases include deployment preparation and

procedures, product deployment, transferring ownership of the product, and closing the

deployment phase. Let's learn about each phase in more detail.

2.6 Maintenance

Matt is a project manager assigned to deliver a software application to an insurance company. After

Matt's project team completes the coding and implementation phases of the software development

life cycle (SDLC), the product is deployed to the insurance company.

Now that the insurance company has the software, and the software is working as intended, Matt's

team meets with the insurance company to provide instructions for the maintenance and upkeep of

the software.

The maintenance phase of the SDLC occurs after the product is in full operation. Maintenance of

software can include software upgrades, repairs, and fixes of the software if it breaks.

P a g e | 10

REFERENCES

  1. Tek4.vn, (2021).Thuật toán là gì?. [online] Available at: https://tek4.vn/khoa-hoc/cau-truc-du-lieu-va-

giai-thuat/thuat-toan-la-gi-moi-lien-he-giua-cau-truc-du-lieu-va-thuat-toan [Accessed September 27,

2021].
  1. Donald E. Knuth. 1968. The Art of Computer Programing. Vol. 1
  2. RELAVANT,(2021). SDLC. [Online] Avaiable at : https://relevant.software/blog/7-steps-for-

effectivesoftware-product-development/ [Accessed 3 October. 2021].

  1. Anon, (2021). [online] Available at: https://codeasy.net/lesson/c_sharp_compilation_process

[Accessed 3 October 2021].

  1. https://junilearning.com/blog/guide/what-are-algorithms/ [Accessed 3 October 2021].
  2. https://www.techopedia.com/definition/3739/algorithm#:~:text=In%20its%20purest%20sense%2C%

0an,but%20how%20to%20do%20it. [Accessed 3 October 2021].

  1. Indicative,(2021). What Is A Programming Algorithm?. Online] Avaiable at:

https://www.indicative.com/resource/programming-algorithm/ [Accessed January 10, 2021].