8:51 am - Friday April 20, 2018

Tag Archives: substring in java

Vector Example Program for lastIndexOf(Object o)

/** @AUTHOR: candid java @DESCRIPTION: coding for find the specific object index */ import java.util.Vector; public class LastIndexOf { public static void main(String[] args) { Vector v = new Vector(); //create a Vector...

Stack Example Program for lastIndexOf(Object o,int index)

/** *@author :CandidJava.com *@descriptions : This program explain the function and use of indexOf(Object o,int index) */ import java.io.*; import java.util.*; public class StackIndexOf { public static void main(String arg[])throws...

ArrayList Example Program for indexOf(Object o)

/** *@author :CandidJava.com *@descriptions : This program explain the function and use of int indexOf(Object o).It is used get index value for specfied element */ import java.io.*; import java.util.*; public class ArrayListIndexOf { public...

ArrayList Example Program for contains(Object o)

/** *@author :CandidJava.com *@descriptions : This program explain the function and use of boolean contains(Object o).It is used to check whether given element exist in the List or not */ import java.io.*; import java.util.*; public...

ArrayList Example Program for lastIndexOf(Object o)

/** *@author :CandidJava.com *@descriptions : This program explain the function and use of lastIndexOf(Object o).It is used to get index value for specfied element occurring at last */ import java.io.*; import java.util.*; public class...

Long Example Program for valueOf(String s,int radix)

/** @author: candidjava @description: valueOf(String s,int radix) is return a Long object holding the value represented by the string argument in the specified radix. */ public class DeeValueOfStringRadixLong { public static void main(String[]...

Long Example Program for valueOf(String s)

/** @author: candidjava @description: valueOf(String s) is used to a long object holding the value of specify string */ public class DeeValueOfStringLong { public static void main(String[] args) throws Exception { try{ String s="candid";//get...

Long Example Program for valueOf(long l)

/** @author: candidjava @description: valueOf(long l) is used to Returns a Long instance representing the specified long value. */ public class DeeValueOfLong { public static void main(String[] args) { Long l=new Long(2);//get the...

String Example Program for lastIndexOf(int ch)

/** @AUTHOR: candid java @DESCRIPTION: coding for find the index of the specified character. */ public class LastIndexOfCh { public static void main(String args[]) { String s ="Application based software"; ...

String Example Program for length()

/** @author: candidjava @description: length() is used to find the length of the string. */ public class DeeLength { public static void main(String[] args) { String s="candid java";//get the string System.out.println("string...

String Example Program for lastIndexOf(String str,int fromIndex)

/** @author: candidjava @description: lastIndexOf(String str, int fromIndex) is used to the new string is in given string searching based on index */ public class DeeLastIndexOf { public static void main(String[] args) { String s1="candid...

String Example Program for equalsIgnoreCase(String anotherString)

/** @author: candidjava @description: to get two strings and to compare use equalsIgnoreCase() method. This method is used to compare the strings to ignore the case. If same means return true otherwise return false. */ public class DeeEqualsIgnoreCase { public...

String Example Program for endsWith(String suffix)

/** @author: candidjava @description: to get one string statements, and endsWith() method is used to find the given string is same as the statement end values, if same means return true values otherwise return false value. */ public class...

Strings in java with Example Program

Strings  The Java platform provides the  strings class to create and manipulate strings. Strings are a sequence of characters. In the Java programming language, strings are objects. The String class is immutable, so that once it is created...