https://codesankalpa.com

Introduction

C is a general-purpose programming language created by Dennis Ritchie at the Bell Laboratories in 1972.

Steps for learning English Language

Steps for learning C Language

Input unit:
This is the receiving section of the computer. It obtains information from various input devices and places this information at the disposal of the other units. Most information is carried into computers today through keyboards and mouse devices. Information can also be entered by speaking to your computer and by scanning images.

2.Output unit:
This is the shipping section of the computer. It takes information that has been processed by the computer and place it on various output devices to make the information available for use. Most information output from computers today is displayed on screens, printed on paper.

3.Memory unit:
This is the warehouse section of the computer. It retains information that has been entered through the input devices. This memory unit also retains processed information until that information can be placed on output devices, by the output devices. This Memory unit is also called memory or primary memory.

4.Arithmetic and Logic unit (ALU) :
This is manufacturing unit of the computer. It is responsible for performing calculations such as addition, subtraction, division and multiplication. It contains decision mechanisms to find the logical relation between two variables.

5.Control unit:
The control unit controls all the component activities of the computer. It sends command and control signals and finds the sequence of instructions to be executed.

6.Central processing unit:
Control unit, memory unit and ALU constitute central processing unit.

                                               OPERATING SYSTEM (OS)

 

An operating is a program which connects the user and the electronic hardware in a computer. It has a set of programs which su

pervise the activities of a computer and activate the operations of the hardware components such as main memory, disk drives, keyboard, monitor, printer and so on.

 

Three major stages of evolution of OS:

1. Batch processing: performing one task or job at a time.

2. Multiple processing: it involves simultaneous operation of many jobs on the computer.

3. Time sharing system: this OS allow many users to share the computer at a time There are 3 types of programming        languages

1. Machine languages:

i) These are the low-level languages directly used by the computer.

ii) The instructions of these languages consists of stings of binary digits 0 and 1.

iii) These languages do not require translators because machine code will be directly understood by the computer.

iv) These languages are machine dependent.

2. Assembly languages:

i) Programming in low-level languages is very difficult. Therefore middle-level languages are developed.

ii) The instructions of these languages consists mnemonics. Mnemonics are the English like

abbreviations to represent the elementary operations of the computer.

Example:

LOAD A

ADD B

STORE C

iii) Assembly languages require translator programs, called assemblers. Assemblers convert

assembly language programs machine level languages.

3. High-level languages:

i) To write complex programs in assembly languages is difficult. So high-level languages are developed.

ii) In these programs single statements accomplish, that particular task.

Example:

C = A + B;

iii) Translator programs called compilers convert high-level language programs to machine language.

iv) PASCAL, FORTRAN,C and C++ are the high level languages.

Assembler, Interpreter, Compiler, Loader, Linker

Assembler:

Assembler is software that converts a program written in assembly language into machine code. There is usually one-to-one correspondence between simple assembly statements and machine language instructions. Since the machine language is dependent on the processor architecture, assembly language programs also defer for different architecture.

Interpreter:

Interpreter performs line by line execution of the source code. Interpreter reads source code line by line, converts it into machine understandable form, executes the line, and then proceeds with the next line. Some languages that uses interpreter are BASIC and PYTHON

Compiler:

A program written in high level language has to be converted to a language that computer can understand i.e. binary form. Compiler is software that translates the program written in high level language to machine language. The program written in high level language is called source code and the compiled program is called object code. The compilation process generally involves two parts. Breaking down the source code into small pieces and constructing the object code. The compiler also reports syntax errors, if any in the source program.