Monday , September 25 2017

Recent Posts

May, 2015

  • 14 May

    TreeSet with Customizable Sorting in Java

    In this tutorials, we are going to learn what is TreeSet in Java and how to apply customized sorting on TreeSet. TreeSet in java is the implementation of the NavigableSet. The underlying data structure for TreeSet is Balanced Tree. Since it is a Set, it doesn’t allow the duplicate values …

    Read More »
  • 13 May

    Serialization and DeSerialization Example in Java

    Serialization Serialization is the process of storing the state of an object to a sequence of bytes in the secondary storage device. If we want to make a class as Serializable, we should implement the java.io.Serializable interface, It is a marker interface. By knowing the values associated with the properties, …

    Read More »
  • 12 May

    How HashSet works in Java

    Java Collection Framework provides a set of interfaces and implemented classes. The HashSet is the direct implementation of the Set interface. Which provides the functionality to store the collection of Objects. HashSet in Java The underlying datastructure of the HashSet is a Hash Map. When we create a HashSet Object, …

    Read More »
  • 11 May

    Java Main Method – public static void main(String args[])

    In Java main method is an entry point of any core Java program. Why I am mention specifically as core Java program is, in other than core Java programs like Servlets, applets and any Java based frameworks, can have their own life cycles and have their own entry points. For …

    Read More »
  • 9 May

    user defined exceptions in Java

    User defined exceptions in Java are used to handle the application specific error conditions. Here application specific error conditions are bound to a specific application those are not generic for all the applications. The guys implemented the Java API, provide us extreme Exception handling mechanism which were generic for all …

    Read More »
  • 9 May

    String sorting in Java

    Java api makes the sorting vary easy with respect to the Strings. In the previous tutorials we have discussed about the bean sorting using comparator interface and comparable interface. when comes to the string array we don’t want to implement any such kind of interfaces to sort a string array. …

    Read More »
  • 9 May

    Top 10 Exceptions in Java

    When unwanted, unexpected event that disturbs the normal flow of our program is called Exception. We have discussed about what is exception and how to handling exception in Java in the previous tutorial. Now we are going to discuss about top 10 Exceptions in Java. Based on the source, who …

    Read More »
  • 9 May

    Binary Search using Java

    If we have ‘n’ records which have been ordered by keys so that x 1 < x 2 < … < x n . When we are given a element ‘x’, binary search is used to find the corresponding element from the list. In case ‘x’ is present, we have …

    Read More »
  • 9 May

    Linear Search using Java

    There are basically two aspects of computer programming. One is data organization also commonly called as data structures. Till now we have seen about data structures and the techniques and algorithms used to access them. The other part of computer programming involves choosing the appropriate algorithm to solve the problem. …

    Read More »
  • 8 May

    How to Search a file in a Directory using Java

    In the previous tutorial we have seen about count number of lines characters and words in a file Java. In this tutorial we are going to see How to Search a file in a Directory using Java. It a common scenario to search a file in our computer system. it is …

    Read More »
  • 8 May

    count number of lines characters and words in a file Java

    In any Java technical Interview it is a common question asked by the interviewer, how to count number of lines characters and words in a file Java. Here is the example. count number of lines characters and words in a file   To run the above example, you have to …

    Read More »
  • 7 May

    Difference between Linkedlist and Array

    Linked lists and arrays are similar since they both store collections of data. Array is the most common data structure used to store collections of elements. Arrays are convenient to declare and provide the easy syntax to access any element by its index number.Once the array is set up, access …

    Read More »
  • 7 May

    What is Linked List

    A linked list is a non-sequential collection of data items. It is a dynamic data structure. For every data item in a linked list, there is an associated pointer that would give the memory location of the next data item in the linked list. The data items in the linked …

    Read More »
  • 6 May

    Writing data to a file in Java

    The most important question when we attend an interview on ios in Java, how to write data in a file using java. Well here is the example, in which we are going to write the data in a file. Writing data to a file in Java To run the above …

    Read More »
  • 6 May

    What is an Algorithm ?

    An algorithm is a finite sequence of instructions, each of which has a clear meaning and can be performed with a finite amount of effort in a finite length of time. No matter what the input values may be, an algorithm terminates after executing a finite number of instructions. In …

    Read More »