public Infix2Postfix(String exp){
		
		String str = "";
		infixExp = exp;
		stack = new Stack<String>();
		
		for (int i=0;i<infixExp.length();i++){
			/* 
			 * If the character is a letter or a digit we append it to the postfix 
			 * expression directly. 
			 */
			str = infixExp.substring(i,i+1);
			if(str.matches("[a-zA-Z]|\\d"))
				postfixExp += str;
			else if (isOperator(str)){
				/*
				 * If the stack is empty we directly push the current char into it.
				 */
				if (stack.isEmpty()){
					stack.push(str);
				}
				else{
					/*
					 * If the current character is an operator, we need to check the stack 
					 * status then, if the stack top contains an operator with lower
					 * precedence, we push the current character in the stack else we pop
					 * the character from the stack and add it to the postfix string. This 
					 * continues till we either find an operator with lower precedence in the 
					 * stack or we find the stack to be empty.
					 */
					String stackTop = stack.peek();
					while (getPrecedence(stackTop,str).equals(stackTop)&& !(stack.isEmpty())){
						postfixExp += stack.pop();
						if (!(stack.isEmpty()))
							stackTop = stack.peek();
					}
					stack.push(str);
				}
			}
		}
		// In the end just append all the operators from the stack to the postfix expression.
		while(!(stack.isEmpty()))
			postfixExp += stack.pop();
		// Print out the postfix expression
		//System.out.println("The postfix form of the expression you entered is: " + postfixExp);
		returnS=postfixExp;
	}