










































Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
Procedural Programming_ Assignment 1 of Information technology
Typology: Summaries
1 / 50
This page cannot be seen from the preview
Don't miss anything!











































Grade: Assessor Signature: Date: Signature & Date:
ASSIGNMENT 1 BRIEF Unit Number and Title Unit 0: IT Fundamental & Procedural Programming Academic Year 2021 Unit Tutor Assignment Title Assignment 1: Analysis and Design a solution for procedural programming problem Issue Date Submission Date IV Name & Date Learning Outcomes and Assessment Criteria Pass Merit Distinction LO1 Understand the principles of procedural programming LO2 Be able to design procedural programming solutions P1 Provide an introduction to procedural programming M1 Discuss on characteristics and features of procedural programming D1 Critically evaluate the design of your solution against the characteristics and features of procedural programming. P2 Identify the program units and data and file structures required to implement a given design M2 Review the design of a procedural programming solution. P3. Design a procedural programming solution for a given problem Assignment Brief
Submission 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.
Table of Contents P1. Provide an introduction to Procedural Programming: ……………………………………………... 1 1.Introduction to computer programming language: …………………………………………………. 1 1.1. Low-Level language and high-level language:.............................................................................. 2 1.2. Command language, compiled language and interpreted language:………………………….. 5 1.3. Criteria for choosing a program language to use:………………………………………………, 8
2. Introduction to Procedural Programming:....................................................................................... .. 3. Key features of Procedural Programming:....................................................................................... 10 4. Advantages and Disadvantages of Procedural Programming: .......................................................... P2. Identify the program units and data and file structures required to implement a given design: ...................................................................................................................................................... 13 1. The variables and data types required :............................................................................................ 1.1. The variables:............................................................................................................................. 1.2. The data types in C programming:............................................................................................. 2. Five data types in Procedural Programming:................................................................................... 15 2.1. String Data Type:....................................................................................................................... 2.2. Character Data Type:................................................................................................................. 2.3. Integer Data Type:..................................................................................................................... 2.4. Float Data Type:......................................................................................................................... 2.5. Boolean Data Type:.................................................................................................................... 3. Selection structures:......................................................................................................................... 17 3.1. If statement:.............................................................................................................................. 3.2. If-else statement:....................................................................................................................... 3.3. If-else if statement:.................................................................................................................... 3.4. Switch-case statement:..............................................................................................................
P1. Provide an introduction to Procedural Programming: 1.Introduction to computer programming language:
before execution. Because computers can only understand the machine language, all high or low languages must be converted into machine language. Language language translates into low-level language. With the help of these languages, we can write mobile applications on many different platforms and are independent of all architectures. High-level high-end language and user friendly. Low-end language is suitable for developing new operating systems or writing basic program code for microcontrollers. High-level language is a highly abstract language compared to computer languages. Low-level language is a language that is closely related to computer hardware, so the speed will be faster. High-level language is more flexible. They are mainly used to write software that can run on multiple platforms and architecture. Low-level programming language is really confusing, the code is written for an assembly language that cannot be run on a different language. In addition, high-level languages are the place where all new creative things are created and it can be much easier to fix bugs than low-level language. Low-level language really challenges programmers Page | 4
and requires a lot of experience and knowledge we have. 1.2. Command language, compiled language interpreter language: Page | 5
Command language can express complex possibilities rapidly. Compiled language: is a programming language whose implementations are typically compilers (translators that generate machine code from source code), and not interpreters (step-by-step executors of source code, where no pre-runtime translation takes place). The term is somewhat vague. In principle, any language can be implemented with a compiler or with an interpreter. A combination of both solutions is also common: a compiler can translate the source code into some intermediate form (often called p-code or bytecode), which is then passed to an interpreter which executes it. Programs compiled into native code at compile time tend to be faster and more efficient than those translated at runtime due to the translation process's overhead. Newer technologies such as just-in-time compilation, and general improvements in the translation process are starting to narrow this gap, though. Mixed solutions using bytecode tend toward intermediate efficiency. They also give the developer more control over hardware aspects, like memory management and CPU usage. Compiled languages need a “build” step – they need to be manually compiled first. You need to “rebuild” the program every time you need to make a change. Examples of pure compiled languages are C, C++, Erlang, Haskell, Rust, and Go. Interpreted language is a computer program that repeatedly reads instructions (one at a time) and translates them to machine code. It then executes instructions written in a programming or scripting language, without requiring them previously to have been compiled into a machine language program. An interpreter generally uses one of the following strategies for program Page | 7
execution: ● Parse the source code and perform its behavior directly. ● Translate source code into some efficient intermediate representation or object code and immediately execute this. ● Explicitly execute stored precompiled code made by a compiler which is part of the interpreter system. Interpreted languages were once significantly slower than compiled languages. But, with the development of just-in-time compilation, that gap is shrinking. Examples of common interpreted languages are PHP, Ruby, Python, and JavaScript. 1.3. Criteria for choosing a program language to use: The right selection of programming language yields solutions that are concise, easy to debug, easy to extend, easy to document, and easy to fix. The support and community. It is very important to consider the platform on which the program will run. Say you have two Page | 8
based on the concept of the procedure call. Procedures (a type of routine or subroutine) simply contain a series of computational steps to be carried out. Any given procedure might be called at any point during a program's execution, including by other procedures or itself. The first major procedural programming languages appeared circa 1957–1964, including Fortran, ALGOL, COBOL, PL/I and BASIC. Pascal and C were published circa 1970–1972.
Procedural programming has program code that is harder to write when procedural programming is employed. The Procedural code is often not reusable, which may pose the need to recreate the code if it is needed to use in another application. Difficult to relate with real-world objects. The importance is given to the operation rather than the data, which might pose issues in some data-sensitive cases. The data is exposed to the whole program, making it not so security friendly.
3. Key features of Procedural Programming: