DOWNLOAD

Get our toolbar!

Saturday, 30 April 2011

// write a program in java which concatenate two string.


CODE

import java.io.*;
public class CombinString{
public static void main(String[] args) throws IOException{
BufferedReader bf = new BufferedReader(new InputStreamReader(System.in));
System.out.println("Enter First String:");
String str1 = bf.readLine();
System.out.println("Enter Second String:");
String str2 = bf.readLine();
System.out.println("CONCATINATE TWO STRING!");
String com = str1.concat(str2);
System.out.println("CONCATINATE STRING: " + com);
}
}

OUTPUT DISPLAY






0 comments:

Post a Comment

Twitter Delicious Facebook Digg Stumbleupon Favorites More