0% found this document useful (0 votes)
96 views32 pages

CCP Unit - 1 Cont

This document provides an overview of how computers work and computer languages at different levels. It explains that users interact with applications, which then communicate with the operating system to utilize hardware components. It also describes low-level machine languages that computers can directly understand, middle-level assembly languages that require translation, and high-level languages that are easier for humans but require compilation. The document outlines the compilation process and execution of programs, and discusses advantages and disadvantages of different language levels. It also briefly introduces the software development life cycle.

Uploaded by

bhuvaneshwari
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
96 views32 pages

CCP Unit - 1 Cont

This document provides an overview of how computers work and computer languages at different levels. It explains that users interact with applications, which then communicate with the operating system to utilize hardware components. It also describes low-level machine languages that computers can directly understand, middle-level assembly languages that require translation, and high-level languages that are easier for humans but require compilation. The document outlines the compilation process and execution of programs, and discusses advantages and disadvantages of different language levels. It also briefly introduces the software development life cycle.

Uploaded by

bhuvaneshwari
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 32

CCP unit -1

Introduction
How does Computer work?
When a user wants to
communicate with the computer,
the user interacts with an
application. The application
interacts with the operating
system, and the operating system
makes hardware components to
work according to the user given
instructions. The hardware
components send the result back
to the operating system, then the
operating system forwards the
same to the application and the
application shows the result to
the user.
Computer Languages
Computer languages are the languages through which the user can communicate with the
computer by writing program instructions.
Low-Level Language (Machine Language)
• Low-Level language is the only language which can be understood by the computer. Binary Language is an example of a low-level
language. 
• The binary language contains only two symbols 1 & 0. 
• Low-level language is considered as the First Generation Language (1GL).
• As the CPU directly understands the binary language instructions, it does not require any translator. CPU directly starts executing the
binary language instructions and takes very less time to execute the instructions as it does not require any translation.
Advantages
• A computer can easily understand the low-level language.
• Low-level language instructions are executed directly without any translation.
• Low-level language instructions require very less time for their execution.
Disadvantages
• Low-level language instructions are very difficult to use and understand.
• Low-level language instructions are machine-dependent, that means a program written for a particular machine does not execute on
another machine.
• In low-level language, there is more chance for errors and it is very difficult to find errors, debug and modify .
Middle-Level Language (Assembly
Language)
• Middle-level language is a computer language in which the instructions are created using symbols such as
letters, digits and special characters. Assembly language is an example of middle-level language. In assembly
language, we use predefined words called mnemonics. Binary code instructions in low-level language are
replaced with mnemonics and operands in middle-level language. But the computer cannot understand
mnemonics, so we use a translator called Assembler to translate mnemonics into binary language. Assembler is
a translator which takes assembly code as input and produces machine code as output. That means, the
computer cannot understand middle-level language, so it needs to be translated into a low-level language to
make it understandable by the computer. Assembler is used to translate middle-level language into low-level
language.
• Advantages
• Writing instructions in a middle-level language is easier than writing instructions in a low-level language.
• Middle-level language is more readable compared to low-level language.
• Easy to understand, find errors and modify.
• Disadvantages
• Middle-level language is specific to a particular machine architecture, that means it is machine-dependent.
• Middle-level language needs to be translated into low-level language.
• Middle-level language executes slower compared to low-level language.
High-Level Language

• A high-level language is a computer language which can be


understood by the users. The high-level language is very similar to
human languages and has a set of grammar rules that are used to
make instructions more easily. Every high-level language has a set of
predefined words known as Keywords and a set of rules known as
Syntax to create instructions. The high-level language is easier to
understand for the users but the computer can not understand it.
High-level language needs to be converted into the low-level language
to make it understandable by the computer. We
use Compiler or interpreter to convert high-level language to low-
level language.
Cont..,
• Advantages
• Writing instructions in a high-level language is easier.
• A high-level language is more readable and understandable.
• The programs created using high-level language runs on different machines
with little change or no change.
• Easy to understand, create programs, find errors and modify.
• Disadvantages
• High-level language needs to be translated into low-level language.
• High-level language executes slower compared to middle and low-level
languages.
How to develop a program?

The compilation is the process of converting high-level language instructions into low-level
language instructions. After completing compilation successfully, an executable file is created with
a .exe extension. The processor can understand this .exe file content so that it can perform the task specified in the
source file.
Execution process of C program
• The file which contains c program instructions in a high-level language is said to be source code. Every c
program source file is saved with .c extension, for example, Sample.c.

Whenever we press Alt + F9 the source file is submitted to the compiler. Compiler checks for the errors, if
there are any errors, it returns a list of errors, otherwise generates object code in a file with name
Sample.obj and submit it to the linker. The linker combines the code from specified header file into an
object file and generates executable file as Sample.exe. With this compilation process completes.

Now, we need to run the executable file (Sample.exe). To run a program we press Ctrl + F9. When we press
Ctrl + F9 the executable file is submitted to the CPU. Then CPU performs the task according to the
instructions written in that program and place the result into UserScreen.

Then we press Alt + F5 to open UserScreen and check the result of the program.
• Important Points
• C program file (Source file) must save with .c extension.
• The compiler converts complete program at a time from high-level language to low-level language.
• Input to the compiler is .c file and output from the compiler is .exe file, but it also generates .obj file in this
process.
• The compiler converts the file only if there are no errors in the source code.
• CPU places the result in User Screen window.
WHY USE C?
•POWERFUL and FLEXIBLE
•C is a powerful and flexible language. What you can accomplish with C is limited only by your imagination. The language itself places no
constraints on you. C is used for projects as diverse as operating systems, Word Processors, graphics, spreadsheets, and even compilers for
other languages.
•POPULAR
•C is a popular language preferred by professional programmers. As a result, a wide variety of C compilers and helpful accessories are available
for use by programmers.
•PORTABLE
•C is a portable language. Portable means that a C program written for one computer system (say an IBM PC) can be compiled and run on
another system (say a DEC VAX system) with little or no modification. Portability is enhanced by the ANSI standard for C, the set of rules for
C compilers.
•MINIMUM KEYWORDS
•C is a language of few words, containing only a handful of terms, called keywords, which serve as the base on which the language's
functionality is built. There is a misconception with many that a language with more key words (some times called reserved words) would be
more powerful. This isn't true.
•MODULAR
•C is a modular. C code can (and should) be written in routines called functions. These functions can be reused in other applications or
programs. By passing pieces of information to the functions, you can create useful, reusable code.
•C++ and C
•C++ is a superset of C, which means that C++ contains everything C does, plus new additions for object oriented programming. In learning C,
you are not only learning one of today's most powerful and popular programming languages, but you are also preparing yourself for object
oriented programming. Java, like C++ is based on C. If later on you decide to learn java, you will find that almost every thing you learned
about C can be applied.
Software Development Life Cycle (SDLC)
• It is a process used by the software industry to design, develop and test high
quality softwares.
• The SDLC aims to produce a high-quality software that meets or exceeds
customer expectations, reaches completion within times and cost estimates.
• SDLC is the acronym of Software Development Life Cycle.
• It is also called as Software Development Process.
• SDLC is a framework defining tasks performed at each step in the software
development process.
• ISO/IEC 12207 is an international standard for software life-cycle processes. It
aims to be the standard that defines all the tasks required for developing and
maintaining software.
•The life cycle defines a methodology for improving the quality of software and the overall development
process.
 This information is then used to plan the
basic project approach and to conduct
product feasibility study in the economical,
operational and technical areas.

 Planning for the quality assurance


requirements and identification of the
risks associated with the project is also
done in the planning stage.

 The outcome of the technical feasibility


study is to define the various technical
approaches that can be followed to
implement the project successfully with
minimum risks.
 The product may first be released in
a limited segment and tested in the
real business environment (UAT-
User acceptance testing).

 Then based on the feedback, the


product may be released as it is or
with suggested enhancements in
the targeting market segment.

You might also like