0 나는 자바에서 풀어야하는 "45 + 5 * 4-6"과 같은 문자열 형식의 방정식을 가지고있다.문자열 형식의 방정식을 풀다. 문자열 형식의 수식을 해결할 방법이 있습니까? 출처 2013-05-07 johntom +0 http://stackoverflow.com/a/7441804/418556). – +0 아니면이 [답변] (http://stackoverflow.com/a/3423360/2024761). – SudoRahul
1 확인 Beanshell 이런 식으로 뭔가가 작동합니다 - Interpreter ip = new Interpreter(); ip.eval("res = 45+5*4-6"); System.out.print(ip.get("res")); [이 답변] (에서와 같이 당신은`ScriptEngine`를 사용할 수 있습니다 출처 2013-05-07 07:36:36 +0 감사합니다 bhushan..it는 작동 중입니다 .. – johntom
http://stackoverflow.com/a/7441804/418556). –
아니면이 [답변] (http://stackoverflow.com/a/3423360/2024761). – SudoRahul