package org.local.test;
import java.io.*;
public class HW {
	private static final char patternSymbol='*';
	private final static int letterArrayLength = 5;
	public static void main(String[] args) {
		InputStreamReader inReader = new InputStreamReader(System.in);		
		//BufferedReader input = new BufferedReader(inReader);				
		 try {			   		
			StringBuilder strBuilder = new StringBuilder();
			
			String[] letterH = getLetterH().split("\n");
			String[] letterE = getLetterE().split("\n");
			String[] letterL = getLetterL().split("\n");
			String[] letterO = getLetterO().split("\n");
			String[][] wholeWord = {letterH, letterE,letterL,letterL,letterO};
			String joinedLetter = "";						
						
			for (int i=0;i<letterArrayLength; i++){							
				for (int j=0;j<wholeWord.length; j++){
					String[] currentLetterArray = wholeWord[j];
					strBuilder.append(currentLetterArray[i]+" ");
					strBuilder.append(" ");
				}
				strBuilder.append("\n");
				String phrase = strBuilder.toString();			 
				System.out.println(" ");
				char symbol=(char)inReader.read();//TODO What if user types in console something that won't be able turned into char? f.e '+++'
				phrase=swapSymbols(phrase,symbol);//TODO why is the symbol with defined value used here? here should be the symbol which is defined by user in console
				System.out.println(phrase);
		
				}
			}
				catch ( IOException e){
				System.err.println("During console read the following error occured:\n"+ e.getMessage());	
			}	
				
	}
	
	private static String swapSymbols(String word, char symbol){
		
		// char to string
		 /*char[] symbols={symbol};
		 String symbolStr= new String(symbols);*/
		 //  +  char to string;
		// char to string
		 /*char[] symbols={symbol};
		 String symbolStr= new String(symbols);*/
		 //  +  char to string
		return word.replace(patternSymbol,symbol);		
	}
	
		protected static String getLetterO() {
		// TODO Auto-generated method stub
		String letterO=   " * \n* *\n* *\n* *\n * ";
		return letterO;
	}	

	private static String getLetterL() {
		// TODO Auto-generated method stub
		String letterL=   "*  \n*  \n*  \n*  \n***";
		return letterL;
				
	}

	private static String getLetterE() {
		// TODO Auto-generated method stub
		String letterE=   "***\n*  \n***\n*  \n***";
		return letterE;
	}

	private static String getLetterH() {
		// TODO Auto-generated method stub
		 String letterH =   "* *\n* *\n***\n* *\n* *";
		 return letterH;
	}
	
	private static String getLetterR(){
		String letterR=   "****\n* *\n***\n** \n* *";		
		return letterR;
	}

	private static String getLetterW(){
		String letterW=   "* *\n***\n* *";		
		return letterW;
	}	
	private static String getLetterD(){
		String letterD=   "***\n****\n***";			
		return letterD;
	}

	
}	
@@ -589,32 +589,179 @@
 ).split(%22%5Cn%22);%0D%0A
+%09%09%09String%5B%5D letterW = getLetterO().split(%22%5Cn%22);%0D%0A%09%09%09String%5B%5D letterR = getLetterO().split(%22%5Cn%22);%0D%0A%09%09%09String%5B%5D letterD = getLetterO().split(%22%5Cn%22);%0D%0A
 %09%09%09String%5B%5D%5B%5D wh
@@ -811,16 +811,57 @@
 ,letterO
+,letterW,letterO,letterR,letterL,letterD,
 %7D;%0D%0A%09%09%09S
@@ -887,19 +887,16 @@
 = %22%22;%09%09%09
-%09
-%09%09
 %0D%0A%09%09%09%09%09%09
@@ -911,17 +911,17 @@
  (int i=
-0
+1
 ;i%3Clette
@@ -967,9 +967,9 @@
 t j=
-0
+1
 ;j%3Cw
@@ -1710,16 +1710,21 @@
 %0A%09%09%09%7D%09%0D%0A
+%09%09 %0D%0A
 %09%09%09%09%0D%0A%09%7D

I have done all letters