Docsity

Pearson BTEC HND in Computer Science - Programming assignment, Study Guides, Projects, Research of Java Programming

Partial preview of the text

Download Pearson BTEC HND in Computer Science - Programming assignment and more Study Guides, Projects, Research Java Programming in PDF only on Docsity!

Pearson

Higher Nationals in

Computing (Software

Engineering)

Unit 01: Programming

Assignment

Higher Nationals - Summative Assignment Feedback Form

Student Name/ID btse032201034^3

Unit Title Programming Assignment Number Assignment 01^ Assessor^ Ms. A.M.L. Chamini Submission Date 4 th^ of September 2022 Date Received 1st submission

Re-submission Date Date Received 2nd submission Assessor Feedback: LO1 Define basic algorithms to carry out an operation and outline the process of programming an application Pass, Merit & Distinction Descripts P1 M1 D LO2 Explain the characteristics of procedural, object-orientated and event-driven programming Pass, Merit & Distinction Descripts P2 M2 D LO3 Implement basic algorithms in code using an IDE Pass, Merit & Distinction Descripts P3 (^) M3 D LO4 Determine the debugging process and explain the importance of a coding standard Pass, Merit & Distinction Descripts P4 P5 (^) M4 D Grade: Assessor Signature: Date: Resubmission Feedback:

Assignment Feedback

Formative Feedback: Assessor to Student Action Plan Summative feedback Feedback: Student to Assessor Assessor signature Date Student signature Date

Student Declaration I hereby, declare that I know what plagiarism entails, namely, to use another’s work and to present it as my own without attributing the sources in the correct way. I further understand what it means to copy another’s work.

  1. I know that plagiarism is a punishable offence because it constitutes theft.
  2. I understand the plagiarism and copying policy of the Edexcel UK.
  3. I know what the consequences will be if I plagiaries or copy another’s work in any of the assignments for this program.
  4. I declare therefore that all work presented by me for every aspect of my program, will be my own, and where I have made use of another’s work, I will attribute the source in the correct way.
  5. I acknowledge that the attachment of this document signed or not, constitutes a binding agreement between myself and Edexcel UK.
  6. I understand that my assignment will not be considered as submitted if this document is not attached to the attached. [email protected] Student’s Signature: Date: ( Provide E-mail ID ) (18/09/2022)

4.4 Critically evaluating why, a coding standard is necessary for the team as well asfor the individual ................................................................................................................................... 43 References ..................................................................................................................................... 45

01. Define basic algorithms to carry out an operation and outline the

process of programming an application

1.1 What is an Algorithm Algorithm is a series of steps for solving problem, using a particular technique. Writing an algorithm is one of the first steps taken in preparing a task to be done by a computer. An algorithm must be very precise in terms of the different steps that make up a task. (Bishop, 1982) And the Coding is the process of designing and building an executable computer program to accomplish a specific computing result and is one of the most important tools in the hands of computer programmers. (Singh, 2020) 1.1 (I) Different between Coding and Algorithm In computer programming, the coding is used to define repetitive functions like managing display of a device, validating transactions, etc. Code is an order of steps which is handed over to a computer in such a way and language that it can understand and execute the commands. Algorithms are considered as high level and complex mechanisms with different levels of complexity depending on the type of code used. (Singh, 2020) 1 .1 (II) Flowchart and Pseudocode Flowchart Flowchart is a pictorial representation of an algorithms. Flowchart use an intellectual scheme of operations in boxes connected by lines and arrows that graphically show the flow of control in an algorithm. The main direction of flow is accepted as being top to bottom and left to right. (Anon., 1995)

Ex: - Display ‘Hello’ five times. Advantages and disadvantages Advantages Flowcharts a. Easy to understand. b. It helps in debugging process. c. Programs can be easily analyzed with the help of Flowcharts d. Easy to trace errors. (aggarwal, 2022) Pseudocode a. Can easily modify. b. Implements structured concepts. c. Done easily on word processor.

Disadvantages Flowcharts a. Hard to Modify. b. Structured design elements are nor implemented. c. Special software required. Pseudocode a. Not visual b. Not having an accepted standard.

1.2 Preparing pseudocode to the given scenario

Total income from the rooms.

Gross Income Total expenses

Net operating profit

Debugging Finding and fixing any faults or problems that were discovered is crucial. Debugging is the term for this. This is accomplished by repeatedly executing the software. Final documentation When the program is tested and debugged, it is documented. By documenting it, the user can execute the software as efficiently as possible, and any other programmers can tweak it as needed.

1.4 Comparison between Algorithm and Program

A program is a set of instructions for a specific goal, but an algorithm is a sequential, logical approach. An algorithm is a methodical technique for tackling a particular problem. In order to program more effectively, programmers need to have a solid understanding of algorithms. Programmers should be equally aware of the distinctions between algorithms and programs. Problems are solved by computer algorithms, which are then implemented by computer programs in a way that a computer can carry out. The key distinctions between algorithms and programs are as follows

2. Programming paradigm

A paradigm is a strategy for tackling a challenge or completing a task. Programming paradigms are ways to solve a problem using a programming language, or ways to use tools and techniques that are available. There are multiple programming languages, all languages need to follow some strategies when implemented. These strategies or methods called as paradigm. There are lots of paradigms to fulfill every demand. (Rani, 2022) 2.1 Procedural programming paradigm A procedural programming paradigm defines as a programming paradigm that allows being organized to a program, as a set of functions. It aims to divide a large program into small procedures that can be manageable. In this case, a program is primarily comprised of a sequence of instructions that guide the computer to do a task, such as reading user inputs, completing the calculations and printing the output. Procedures are also known as subprograms, subroutines, methods, or a function.

Some programming languages that cam implement procedural programming are, Java, C, C++, Pascal, CloudFusion 2.1 (I) Characteristics of a procedural programming

  • Procedures and functions are the small, manageable components that can be used to divide a huge program into manageable units. As a result, there is less redundant code, which enhances a code's readability and maintainability.
  • Global variables allow for the sharing of data between multiple functions. Functions are entirely segregated, thus if we want to communicate data, we must declare it in the upper scope.
  • The transfer of global data between functions. Functions can affect global data because during transformation, the global data is changed in function chains.
  • Because procedural programming employs a top-down approach. Workflow therefore moves from top to bottom. 2.1 (II) Advantages and the Disadvantages of the Procedural programming Advantages
  • Simplicity – it is frequently working simply and simple to comprehend
  • Versatility – professionals can use the procedural coding language for most common programming tasks. It is easy to use for basic projects
  • Testability – It is easy to read, track and test.
  • Reusability- It has reusable parts of the codes, through the same project without manually copying.

2 .1 (III) Disadvantages Prioritizes operations - It might not be appropriate for projects involving data-sensitive materials since it prioritizes procedures and functions over data. Exposes data - Procedural programming doesn't provide as much security as other coding languages because every data entered into the code is visible during the entire process. Offers single-use - Professionals cannot reuse the same code for other projects even though procedural programming language features allow for partial reuse for the same project. 2.2 Object-oriented programming paradigms A programming paradigm known as object-oriented programming (OOP) links the structures of data with a group of operators that interact with the data. An object is a specific instance of such a thing. In other terms, OOP refers to a programming approach where objects are the building blocks of programs. These objects each stand for a particular class instance. All classes belong to a hierarchy of classes that are connected by the idea of inheritance. C++, C#, Java, JavaScript, Visual Basic.NET, and Python are a few examples of OOP languages. There are mechanisms in every OOP language that aid in the implementation of the object-oriented model. They are inheritance, polymorphism, reusability, and encapsulation.