Computer Programming

Computer programming is defined as process of writing a set of instructions called program that directs the computer to perform a specific task. The set of instructions are written in programming language that computer can decode and execute.

The Computer Programming continues to be the most popular choice for students opting a career in computer science. Learning Computer science is now considered to be one of the best career option . 

The Computer programming expertise can get you your dream job with top notch technology company as a software developer with excellent financial rewards . The computer programming skills can put your career on the fast track. 

Computer Programming , Coding , Computer Program

computer program  is a set of statements  written in a computer programming language which directs the computer hardware  to  perform  specific  operations. 

A  computer program  can be written  in any programming  language  depending upon the purpose and  type  of  the software  being  developed.

In this tutorial , we will learn what is a computer program, how program works, program compilation, and other important topics related to the computer programming.

Computer Programming - FAQ

  Some of the most common and frequently asked questions related programming include :

What Is Computer Programming ?

Let us first understand what is  a Computer System . A  Computer system can also be defined as  programmable electronics  device  that  can  be programmed  to accept  some  inputs  in  terms of  data  , then process  this  data as per the program instructions   and  provide  the  Output  in  the  desired  format  that can be used for some meaningful  work .

The Computer System must be first programmed  to perform a specific job on the computer . Further , the Computer  is  a  digital  electronic  machine .  

That means  , the computer  can understand  and  execute  instructions  on  in  binary  which consist  of  only two numbers that  is  0  and  1 . 

The  binary  code  is also referred  as machine code  or machine language .

Computer System Software Components
Computer Components

What Is Computer Program ?

A computer program is a group of instructions written using a computer programming language ( Such as C , C++ , Java , Python ) . 

The computer programs are written to perform a specific task . For example , A computer Program ( Software ) to play music in your computer OR to play game and so on.

Each computer program usually consist of number of program statements . Each program statement performs a part of the job . The programmer must write the program statements as the programming language syntax . 

Computer Program Compilation

Each programming language has its own syntax ( Set Of Rules ) which clearly defines the manner in which the computer program statements can be constructed. 

The programmer can choose any programming language of his choice depending upon the type of the software application to be developed .

Computer Program Compilation

The computer system only understands and can execute program statements in Machine Code which is in Binary consisting of only two digits , that is 0 ( zero ) and 1 ( one ).

The CPU ( Central Processing Unit ) is the system  brains . The CPU can decode and execute only program instructions in binary.

And therefore, the computer programs written in any high level programming language must be first converted into machine code in binary.

Program Compilation

This conversion process is referred as program compilation. Each programming language has its own compiler which converts the program code into executable program ( Machine code in Binary ) . The converter program is referred as compiler .

How Computer Program Is Executed ?

The program execution starts when the user gives the command to the operating system to run any program. 

The operating system then initiates the program execution by allocating the necessary resources such as memory and the processor time.

The operating system then loads the program executable copy and its data into the main system memory RAM. 

The Central Processing Unit ( CPU ) starts the program execution by fetching the program instructions and data from the main memory RAM. 

Computer Programming

The CPU operates on the data as per the program instruction and the processed data ( Result ) is then either sent to a output device such as display monitor Or could be stored into any permanent storage ( Secondary Storage ) device  such as hard disk for future use .

Types Of Programming Languages

The  programming  languages are generally classified  as  high  and low level language . The  higher level programming  languages  are more human readable  and the  lower level programming  languages are machine readable. However, the computer system can execute only low level programs in machine code in Binary.

The  computer  programming  languages  are   classified  on the  basis  of   ease  of  readability  of the language , program execution  speed  and  the level of abstraction in the programming  language.  

 The  computer programs are generally  written in higher level  programming languages such as  Java  , C++  , Python  which  provides  a high degree of abstraction  and  mask  the complexity  of   the  low  level programming language such as assembly language .

Levels Of Programming Languages

Types Of Programming Language

The  high  level  programming languages  are  more human  readable  whereas  the low level  programming languages  provide least  abstraction.

And therefore,  it is relatively  far more difficult  to  read  and write the program in  low level  language  such as assembly  language . 

The  program  execution  speed  is  higher   for  the programs written  in  low  level  language  whereas  the  programs written  in  high level language have  relatively  lower  execution speed .

Computer Programming

Compiled Vs Interpreted Programming Language

Depending upon the type of programming language , A computer program can either be compiled or interpreted during its execution .Compiler and Interpreter are two different ways to execute a program code . 

The computer program can be either written in a programming language or scripting language. 

During the compilation process , A compiler takes the entire program code and converts it into object code which is typically stored in a file. The object code contains library references  which is replaced by actual binary code by the linker . 

The binary code after linking the object code can be directly executed by the computer system. Examples of compiled programming languages are C and C++

Compiled Program

Program Compilation

Interpreted Program

Program Compilation Interpreter

Whereas an Interpreter directly executes instructions line by line written either in a programming language or scripting language without any prior converting them to an object code or machine code. 

The Python is an examples of interpreted language. Similarly , the java program is first compiled to an intermediate byte code , which is then executed by the Java Virtual Machine ( JVM ).

Application Programming

Software , Software Package , Software Application

The application programs are developed to provide solution to specific user problem . The application programs are also referred as application software or simply an application.  

The application programs provide an interface to the user for using the computer system for specific purpose .

For example , the user might work on the accounting software for accounting jobs . The most commonly used application software are Microsoft Word , Excel  and PowerPoint . 

The Application software provide a very user friendly graphical interface to get the specific job done for which that application software has been designed.

Application Software
Computer Architecture

System Programming

System Software , System Program

The System Software  is a collection of programs provide interface to interact with computer hardware. The system programs are designed to operate , control and extend  the processing capabilities  of  the computer system  itself .

The system  software programs are usually  designed and developed  by the computer manufacturer to  communicate  with  specific  hardware components connected  to  the  computer system such as device driver software necessary to connect that hardware to the computer system.  

An Operating System is an essential component for all computer systems .The operating system provide an interface to the user to communicate with the system hardware. 

The  operating system ( OS ) is the most commonly used example of system software. The Operating System manages all the application programs and  the hardware components attached to the  computer system.

System Utility Programs
Types System Programs

The  operating system  makes use of  some system software  called as utility software which allows   the user  to  manage  the  computer system.  

There are many different utility programs for different purpose and they may vary across operating systems. These utility software can be accessed by the  user  via a special menu or control panel  in  the   operating system .

Program Compilation

A   Computer  program  is  a  set  of instructions  written  by  a  programmer  in a computer  programming  language . 

Each   computer  system  has  a  CPU  ( Processor )  which  is the brain of  the system . The CPU is responsible to decode and execute the program.

The  CPU  is  the main component  which  performs  arithmetic  calculations  and logical operations .  

However , The CPU can  understand and execute  program  instructions  only  in  machine code which is binary representation consisting of   0  ( zero ) and 1 ( one ).

Program Compilation

All  computer programs  must  be first converted ( either compiled  or interpreted )  to machine code  before  it can be  executed  by   the   computer  .    

A  Program compilation is a process in which  a human readable program code written in  any programming  language  (  such as C , C ++ , Java , Python )  is converted  into a  machine readable code  in  binary  (  using  only 0’s  and 1’s  ).

This program conversion to binary code is done by  using  a special  program  called either compiler  OR  Interpreter  depending upon the type of the programming language .

Four Stages Of Program Compilation

The  compiler  only  converts  the  program source code  in  to  the  Object code ( Binary Code )  . The   object code  cannot  be directly  executed  by the  operating system .

The  Object code  file  needs to be  further  processed  by  another  program  called   “Linker”   which   is  built  in  to  the  compiler .

The  compiler  may produce  number  of  object code files for a single program source  code  file . The object code   consist  of  machine code  instructions  in  binary  which  is  equivalent  of  corresponding  high level  program  instructions  in  program  source  file . 

And therefore ,  linking  is  needed  to link  all  object code files  and  other  files  together  to  create  an  “Executable”  file .  

Compilation in Programming
Object Linking In Compilation

The  programmer can  use   these  user defined   functions  and standard function  libraries  by simply  including  these files in the beginning of the program  header  section  .  

Since  the  standard  library  code  is in the object code  form  which is a   pre-compiled   format  and  can be directly  included  in  the  linking  stage  by  the  linker   while  creating an  executable  file (  sourcefile.exe  )  during  the  program  compilation  process .

The  programmer can  use   these  user defined   functions  and standard function  libraries  by simply  including  these files in the beginning of the program  header  section  .  

Since  the  standard  library  code  is in the object code  form  which is a   pre-compiled   format  and  can be directly  included  in  the  linking  stage  by  the  linker   while  creating an  executable  file (  sourcefile.exe  )  during  the  program  compilation  process .

Computer Program Compilation And Linking

During final stage of compilation  process , whenever  the linker finds a reference to a library routine in the object file, it reads the library files  ,then finds that routine and  replaces the programmer’s reference with  the  actual  code  for  the  routine  from  the  library file.  

After it has replaced all the references with  actual code from the library files  , the linker then creates  an executable  binary file  which  can be executed by the  operating system ( OS ).     

Programming Paradigms

Types Of Approaches To Organize The Program Code

The  programming languages can also differ on the basis on organizing the program code and manner in which data is handled in the program .   The programming paradigm defines a particular style of writing and organizing the program code .

There are many programming paradigms out of which  the two most important programming paradigms are the procedural paradigm and the Object Oriented Paradigm ( OOP ) .

Programming Paradigms

Procedural Programming

In   procedural  programming  , the  problem is  bifurcated  in to  number  of  small  problems known as procedures ( Also alternately referred as  functions Or methods ) . 

Each  of these procedures provide solution to part of the problem . These procedures can be  called  many times depending upon the algorithm of the program  to solve  a  particular  problem  .

The  procedural  programming  languages are generally the first  preferred choice  for students to  learn the  computer  programming . Some of the most popular procedural languages include C ,  Fortran , Pascal  and Basic.

Procedural Programming

 A procedural program is written as a list of instructions, directing  the computer hardware to step-by-step  to perform desired operation. 

As the name suggest , in this approach  , a group of program statements  is written to solve one task  and declared as a procedure .

The program consist of the main function or program block, subroutines, functions, procedures , header  files , includes / modules , libraries. During the program execution , the a procedure may be invoked number of times.

Limitations Of Procedural Programming

In procedural programming the data ( program variables ) are  mostly  global  and  accessible  to  all the  functions . For  a   large  programs  it  is very  difficult  to keep the  track  of  the  changes  in the  data  being operated  upon  by  many  functions simultaneously . 

Such  changes in the data can adversely affect the functionality  of  other  functions  .  Similarly  ,  when the new data  is added all  the functions  operating  on  that  data also  need  to  be  modified  accordingly  .     

The most serious limitation of the procedural programming is the tendency for large procedural-based programs to turn into “spaghetti-code” since the dada access is not controlled and might get accidently changed by other functions.

The Spaghetti code  is functionally useless program code . It is very difficult  to debug the spaghetti program code  . 

And therefore,   programmer  should follow the standard  best coding practices  to avoid  program resulting in to  such  badly tangled  Spaghetti code .

Structured Programming

The 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  programs  makes  extensive  use of the  program  control  structures such  as  sequence , decision  /  selection  and  repetitions like loops .

Computer Programming
Computer Programming

The Structured programming is a programming paradigm that helps to improve the clarity, quality, and development time of a computer program by making extensive use of procedures, block structures  and looping  structures  like for loop , do while loop  and while loop.

Object Oriented Programming

The Object Oriented Programming ( OOP )   is an approach to software application development where all application components  are treated as objects. An object is a component of a program that has its own data and methods. 

An object knows how to perform certain actions and how to interact with other elements of the program. Objects are the basic units of object Oriented  programming .

In  Object Oriented Programming ( OOP ) , a  Class is simply a description of an object  and the  Class  defines  the  datatype  for  an object .

A  class is a  design time   entity used to define the object. Whereas  an  object   is  a   runtime  entity created during the program execution .

Object Oriented Programming
Java Programming , Computer Programming OPP

 A  class  is the blueprint , or a plan , or a template, that describes the details of an object. A class is the blueprint from which the individual objects are created. 

A Class  is  composed  of   three  things  :

1. Class Name ,  2. Attributes ,  3.  Operations.

Advantages Of Object Oriented Programming

The Programs once developed and operational continues to be in use for a considerable period of time  even if the support is discontinued .Such code is referred as  Legacy code.

The legacy code needs to  be supported , either to be improved upon (  for a new version of an exist piece of software ) or made to work with newer computers and software.

How To Learn Programming ?

A career in computer programming can be very rewarding and  completely worth the time , efforts and patience which you need to invest while learning the computer programming.

Some people initially find learning computer programming  a bit scary and tedious. However , once you learn your the first language than learning the second programming will be much easier.

With the help of best learning practices, you can easily learn the computer programming  without much difficulty. If you follow the right learning strategy then you can learn any  programming language without any problem . 

Now  , Let us discuss this learning strategy in detail .

  • Learn professional programming skills.
  • Learn the Fundamentals Of Computer Science And Programming.
  • Learn Both Theory And Practical. 
  • Learn the Best Programming Practices.
  • Start With Simple Programming Language.
  • Focus on logical thinking.
  • Work On the Project.
Program Control
Programming Languages

Learn To Code

How to learn Computer Programming ?

The computer programming is still continues to be the most favored choice for many students. The financial rewards and career opportunities for a computer science professional are very good . 

And therefore , career in CS is  completely worth the efforts and patience which you need to invest , while the learning programming .

There is a huge shortage of qualified professionals in every field of computer science . An opportunity  in computer science can put your career on the fast track .

Although , some people might  initially find , Learning computer programming  a bit challenging and difficult . But every programmer has to go through this learning curve  and learn to  overcome these challenges .

If you have the right learning strategy in place and follow the best learning practices, you can easily learn the computer programming  without much difficulty.

Read Detailed Article

Computer Programming - FAQ

Computer programming is the process of instructing the computer with a set of instructions called a computer program. The computer program directs the computer which operation is to be performed.

Computer Programming , Coding , Computer Program
Computer Programming , Coding , Computer Program


The computer programmer writes the program code depending upon the program logic and the operation to be performed. 

Computer programs are generally written in high level programming languages which are human readable.

However, computer can decode and execute only binary machine instructions. And therefore, all high level program are compiled ( converted ) to low level machine readable  instruction that computer can directly execute.

Computer Program Compilation
Computer Program Compilation


The application program provide an interface to the user to interact with computer and perform the desired operation.

Application program example include Microsoft Word , PowerPoint , and Excel.

Application Software
Application Software


The system programs are internally used by the computer to communicate with various hardware components and hardware devices connected to the computer.

Some system software are also developed to provide utility services to the user.

Application program example include Operating system such MS Windows.


What is system software
What is system software

A computer programs written in high level programming languages such as C , C++ , Java , Python , JavaScript and other high level programming languages.

The high level indicates the abstraction which makes the program code human readable.

All high level programs are compiled to low level programs prior to execution.

C Program Example , Computer programming, coding
C Program Example

A computer programs written in machine language in Binary is referred as low level program. The low level programs are considered machine readable because it simply contains patters of zero 0 and one 1 used in binary code.

The low level indicates the abstraction which makes the program code machine readable.

All high level programs are compiled to low level programs prior to execution.

Computer Program Compilation And Linking
Computer Program Compilation And Linking

Join The Best Seller

Computer Science Online Course

This is the most comprehensive  and unique  Computer Science  And Programming Fundamentals course Online which will give you in depth understanding of most important fundamental concepts in computer science And Programming .

Don`t copy text!