Search This Blog

COMPUTER SCIENCE CLASS XII

COMPUTER SCIENCE

  1. INTRODUCTION  TO C++
  2. ARRAYS
  3. SORTING   : Sorting tec
    Sorting is arranging the data elements in a particular order. The values in an array or list can either be arranged in ascending or descending order.
    Consider following list of integers as the marks obtained by 7 students in a test:
       3, 12, 6, 8, 5, 9, 15
    After sorting the list elements appear as :
       3, 5, 6, 8, 9, 12, 15
    we may easily find the highest marks and the range of marks in the above list. There are a number of ways to sort a given list of elements. Various algorithms have been devised to sort list of elements . Each sorting technique has its own effective approach depending on situation.
    1. SELECTION SORT 
    2. INSERTION SORT
  4. STACKS
  5. QUEUES

Introduction to C++

Introduction to C++

C++ is an object oriented programming language developed by Bjarne Stroustrup at Bell laboratories.

An object oriented programming language focuses mainly on classes and objects.

Class : It is a group of objects with similar properties and behaviour. 
The term ' class' is used to define the class in C++. Basically, class is a template which defines the structure of the class. For example : car is a class that has a  state( Model, colour, engine, gear etc.)and behaviour (changing gear, speed, applying brakes etc.) 

Let us have a look at the first program in C++

#include<iostream.h>
void main()
{
    cout<<"\n HELLO";
}


Classes in programming : 
Keyword 'class ' is used to define a  class. 
It is used like a template of Abstract Data Type. 
It binds the data with the functions associated with it. 
It is like a blueprint of the data type. 
Networking notes

A computer network allows  one computer to share/ exchange data with another computer.
or when a computer is able to share and exchange data with another computer they are said to be in a network.
Internet: Network of networks is called internet.
Intranet : It a network of networks among computers of same organization.
Extranet : Network of networks of some organisations.

Types of Network

PAN : Personal Area Network
This type of network if confnied within a metre or two.

LAN : Local Area Network
Area of network confined within 1-2 kilometers is  called an LAN

MAN :  Meropolitan Area Network
WAN :  Wide Area Network

Topology : The pattern of arrangement of computers/ nodes in a network is called the topology.