Thursday, 30 November 2017

A Brief Description to Object oriented concept

Problems in using the POP(Procedure Oriented programming)
In actual practice procedure oriented programming is good for solving the small problems because most of the code is not reuse further,secondly we don't have to to deal with the complexity of the OOP thirdly we can write a good readable code by using proper modulation.
But Industries,and scientific area and statistical fields  we have to deal with large programme having millions of lines of code.
Normally when the size of code is below 10,000 to 12,000 line the programmer have a good grief on their code but whenever the program update additional code added to this and gradually the lines of code increase when its reach 90,000 to 100,000 line a point arise when programmers start to loose the control over the program at that time the program have that much flexibility that it harder for a good professional also to know the actual behavior of the code. secondly the code readability also gradually decrease. That''s why POP is not a good way to write a good code.Humans are evolve to deal with object so if we give this Object oriented approach to program then it will be readable and debug able by anybody.
Advantage of using OOP(Object Oriented Programming)
their are several benefits of using the OOP concept.
#Class and Object concept
#Data Abstaction
#Data encapsulation
#Inheritance
#Polymorphsm

Class and Object :
           the entire methodology of OOP is to deal with class and objects.In normal saying class are the the model for creating object and objects are the demonstration of real world or any kind of thing created by the class.It means class are the skeleton of the object.Object have physical significance where class have no physical significance.to understand this concept better take a example
                                      Student is a class it means that any person which have the criteria which are present in the student is called student.let Ram is a person which have these criteria so Ram is also a student.If I ask you to point a student then if you point Ram then this is wrong , why ?? Because you are pointing Ram not a student.Here what i want to tell you that in real world classes have no existence. you can't point out a student,human,person,boy,flower,fruit.or any thing.what you can point is Ram who is a student . yourself who is a human ,mango which is a fruit,lily which is a flower,and so on.

Data Abstaction :
           Abstraction means to hide the unnecessary data.In object oriented programming we have a facility call data hiding which means we can hide some specific data or methods from a specific user group,let take a example
                                   let in student class their are some properties like roll,name,class,mark.Here if their is no Data abstraction then student have the same power as the teacher to change some sensitive data.In real world it is not good you know.so what if we made to methods such that one is used for the Data updation and another is simply viewing purpose.and updation is meant for teacher and viewing is meant for student then we can get some kind of security over our data.Over all i mean to say that Abstraction is displaying only the essential details.

Data Encapsulation:
          Encapsulation is a way by which the data inside the object behave to be bind together what do you mean by capsule.it means a compact,sealed and detachable container or compartment,right??In just the same way Object are also packed with a lot of variable which are normally the properties of object along with methods which are the functionalities of the object.
Encapsulation isolate the properties and functionalities of a class from the other class.

Inheritance:
           Inheritance is a way to create a new class form a old class.by which their is a better readability of the code.and we can make new vlass from a existing class very easily.The old class is called the base class and the new class is called the derive class.the old class is called the super class of the new class and the new class is called the sub class of the old class.many type of inheritance are possible some are like single-Inheritance,multi level inheritance,hierarchical-Inheritance,etc.

Polymorphysm : 
           the word polymophism come from two Greek letter word "poly" and "morphos".poly means many morphos means form it mean polymorphism means many forms.in programming it is the way to handle multiple object with a single reference by which we can do different task with same functionalities.let take a example
                    let student and boy are two different class with different functionalities but with same names if the both class inherited from a class name human then by using the reference variable of the human class we can manipulate two different object like student and boy.though the human functionalities are same but by changing the object the execution of the program change.in this way we can manage multiple object at a time two type polymorphism are their one is compile time polymorphism which is normally called the static binding and another is run-time polymorphism which is called the dynamic binding .


           

           

Thursday, 12 October 2017

Linked list

What is a linked list :-
Linked list are the dynamic data structure which is used in such application which need more memory in the run time. These are the group of Structure or object which  have at least one reference variable and a information part which used to store the data that the application required the Reference variable is used to connect the nodes together .That's why the total structure is called as linked list.
Type of Linked list :-
Linked list is categorized mainly in five type according to their properties and the number of reference variable  they have  i) singly linked list  ii) doubly linked list iii) circular linked list iv)hash linking  v) multiply linked list but we can form more type of linked list by combining the properties of above linked list like Circular singly linked list, Sentinel circular doubly linked list etc.
Advantages of Linked list over traditional array :-
Many advantages of linked list are there to overcome the traditional array. Unlike array, linked list can grow up and shrink down over the execution of the program by which the memory of the system can be use efficiently. Insertion and deletion in the linked list is very easy because the node of the linked list are  not stored  in continuous ,Because of this the modification of linked list take less time. linked list use pointer(a special variable which points others variable ) to refer the other nodes. As the pointer are fast that's why retrieving  the  data is faster  in the linked list. Many abstract data type concept like Stack and Queue are easily implemented on the linked list and because of this efficient algorithm can be used to manipulate the data.
Application of Linked list in real life :-
Now a day  linked list are the internal structure of every program that's you used in your daily life. Database management program like ms excel ,ms Access, Oracle  used the linked list structure to store the data in the system because of which user can put powerful queries to retrieve the data. programmes like games and application that  used the application partially at a time also used the concept of linked list structure for efficient use of the memory. Compiler that  use to write program like c ,c++,java etc also stores the initialized value dynamically in the memory. Linked list concept is also used to give  Object oriented  approach to the programme internally.
Some Disadvantages of Linked list :-
Many disadvantages of linked list are their but in today we have the way by which we can overcome this disadvantages. Mainly linked list need more memory to store a data but in today we have more storage space but less time for execution. As all the node are not stored in continuous form that's why the access time of  each node take some time but if we store them in continuous form then insertion deletion process will take more time. Dynamic array is an example of dynamic allocation of continuous memory but here the insertion and deletion process is not efficient at all. Retrieving  a data is hard because we have to search the data continuously from the first node sequentially. but we have a better algorithm for this to search the data easily. Traversing in linked list in backward is difficult but if we used the doubly concept then we can easily traverse the linked list in backward also.


Thanks for reading please give a comment to improve this article.

Sunday, 24 January 2016

How to Learn Java Quickly

Java is the most popular language tat is used in many industry So if you want to become a developer then java is the best language in where you can increase your skill.

To know java Quickly first you have to get your hand dirty with a procedural language and after that with a Object oriented language

Why procedural language,Because it give you a confidence to write a program and with this you can know how the compiler behave to the program and how the program allocate memory in the memory
C is the best language for a beginner

After Learning a procedural language you have to Get some knowledge about the Object oriented approach so a language like c++ is a good  head start to learn java quickly. You have to give more focus about the concept like Class and Object ",Encapsulation,Data Abstraction,,Inheritance,polymorphisim,Abstract class Concept

After Learning a object oriented language you will ready to learn java. In java Give more trace to Exception handling,Interface ,awt,swing.and if you wan to learn advance java then Jdbc,servlet,Jsp and Hybernet is very important for web application.


Total Pageviews