Question: Can someone please help me with this lab? //(c) A+ Computer Science //www.apluscompsci.com //Name - import java.util.ArrayList; import java.util.Scanner; import static java.lang.Integer.*; import static java.lang.System.*;

Can someone please help me with this lab?

Can someone please help me with this lab? //(c) A+ Computer Science

//(c) A+ Computer Science //www.apluscompsci.com //Name - import java.util.ArrayList; import java.util.Scanner; import static java.lang.Integer.*; import static java.lang.System.*; public class ExpressionSolverRunner { public static void main( String args[] ) { } }

//(c) A+ Computer Science //www.apluscompsci.com //Name - import java.util.ArrayList; import java.util.Scanner; import static java.lang.Integer.*; import static java.lang.System.*; public class ExpressionSolver { //add in instance variables public ExpressionSolver(String s) { } public void setExpression(String s) { } public void solveExpression() { } public String toString( ) { return ""; } }

Lab Goal This lab was designed to teach you more about the ArrayList class. Lab Description Take an expression and solve it. For instance, if you were given 3+4 5, you should come to the answer of 23. This would requlre that you handle the multiplication before the addition. Sample Data 3 + 5 Files Needed ExpressionSolver.java ExpressionSoverRunner.java 5*5+2/2-g+585-2 Sample Output EXPRESSION SOLVER ALGORITHM 3 5-8 35 15 3-52 35 0 55* 2a / 2+5 -11 5 5 2 2 - 8+ 5 5 241 while there are * and / symbols find the 1 * or / operator get the first operand get the second operand get the operator calc the answer remove the first operand remove the operator replace the 2 operand with the new answer do the same thing forand

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!