• Java toString method

    In this blog, we will see java toString method with example. Most of the developer use toString() method for program testing. Statement of toString method public String toString() {             return string_value; } Public is compulsory in this statement Return type is String class   Let’s see example on java toString method   class Employee […]

    Share and Enjoy

    • Facebook
    • Twitter
    • Delicious
    • LinkedIn
    • StumbleUpon
    • Add to favorites
    • Email
    • RSS
  • How to find location of word and character from string?

    In this blog, we will see how to find location of word and character from string. We will use indexOf() and lastIndexOf method. Both methods will return location of word and character. How to find location of word and character from string program class str5 {                 public static void main(String args[])                 {                                 […]

    Share and Enjoy

    • Facebook
    • Twitter
    • Delicious
    • LinkedIn
    • StumbleUpon
    • Add to favorites
    • Email
    • RSS
  • How to check string from front and back?

    How to check string using startsWith and endsWith function? Let’s see videos and program on how to check string using endsWith and startsWith function. In this blog, we will check string from front and back part. startsWith() and endsWith() functions work on check string.   Video On endsWith and startsWith Function   class str4 { […]

    Share and Enjoy

    • Facebook
    • Twitter
    • Delicious
    • LinkedIn
    • StumbleUpon
    • Add to favorites
    • Email
    • RSS
  • String compares function: equals() And compareTo()

    In this blog, we will see equals V/S compareTo , equals V/S equalsIgnoreCase, comapreTo V/S compareToIgnoreCase and How to use string compares function in programs. Let’s see example and video on String compares Function   import java.util.*; class str3 {                 public static void main(String args[])                 {                                 // equals V/S equlasIgnoreCase  – Both […]

    Share and Enjoy

    • Facebook
    • Twitter
    • Delicious
    • LinkedIn
    • StumbleUpon
    • Add to favorites
    • Email
    • RSS
  • 7 String Important Function

    In this blog, we will see 7 String important function like length(), toUpperCase() , toLowerCase() , charAt() , trim() , replace() , concat(). Let’s see example and video on 7 String Important Function   class str2 {                 public static void main(String args[])                 {                                 String str1 = “Welcome in String Class”;                                   // How […]

    Share and Enjoy

    • Facebook
    • Twitter
    • Delicious
    • LinkedIn
    • StumbleUpon
    • Add to favorites
    • Email
    • RSS