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("Combin string example!");
String com = str1.concat(str2);
System.out.println("Combined string: " + com);
}
}In this code, I show how to join two strings in Java.
