Structured Programming Approach Prof: S. Rathod Structured Programming Approach 
Structured Programming Approach Prof: S. Rathod WHY LEARN PROGRAMMING: ❖ A computer is machine. Programming helps you to understand computer. ❖ A program is a set of logically related instruction that is arranged in a sequence that directs the computer in solving problem. ❖ The process of writing a program is called programming. Software: ❖ Software nothing but computer program. Types: System software: It is a collection of program that interfaces with hardware. Example: Language Translator, Operating system Application software: It is enable the computer to solve a specific data processing task PROGRAMMING LANGUAGE: A set of rules that provide a way of telling a computer what operation to perform is called computer programming language. Types: 1) High level: It is used to write application programs. It is easy to prepare and debug. Example: BASIC,COBOL(Common Business Oriented Programming Language) and FORTRAN (formula translation language). 2) Middle level:It is used for writing application and system program. Example: C 
Structured Programming Approach Prof: S. Rathod 3) low level: It is mostly used to write system program. Example: Assembly Language. COMPILER: A compiler is a computer program (or a set of programs) that transforms source code written in a programming language (the source language) into another computer language (the target language), with the latter often having a binary form known as object code. INTERPRETER: Computer language processor that translates a program line-by-line (statement-by-statement) and carries out the specified actions in sequence. The difference between an interpreter and a compiler Interpreter Compiler Translates program one statement at a time. Scans the entire program and translates it as a whole into machine code. It takes less amount of time to analyze the source code but the overall execution time is slower. It takes large amount of time to analyze the source code but the overall execution time is comparatively faster. No intermediate object code is generated, hence are memory efficient. Generates intermediate object code which further requires linking, hence requires more memory. Continues translating the program until the first error is met, in which case it stops. Hence debugging is easy. It generates the error message only after scanning the whole program. Hence debugging is comparatively hard. 
Structured Programming Approach Programming language like Python, Ruby uses interpreters. Prof: S. Rathod Programming language like C, C++ use compilers. LINKER: ❖ Linker convert machine understandable format into Operating system understandable format. ❖ If these piece of code need some other source file to be linked the linker link them to make it a executable file. LOADER: ❖ It is a program used by an operating system to load programs from a secondary to main memory so as to be executed. Usually large applications are written into small modules and are then compiled into object codes. ❖ Loader : is entity which actually load and runs the program into RAM WHAT IS STRUCTURED PROGRAMMING APPROACH? Structured: It means highly organized or arranged in a definite pattern. Programming: Telling computer to do something for us. Approach: It means a methodology used to perform a task ❖ Structured programming (sometimes known as modular programming) is a subset of procedural programming that enforces a logical structure on the program being written to make it more efficient and easier to understand and modify. ❖ Structured programming facilitates program understanding and modification and has a top-down design approach, where a system is divided into compositional subsystems. Process of Programming: 1) Understand the problem to be solved 2) Think and design solution logic 3) Write the program in the chosen programming language. 4) Translate the program to m/c code. 5) Test the program with sample data and Put the program into operation.