konversi notasi infix
source code C++ untuk konversi notasi dari infix ke postfix dan prefix, sbb:
#include <vector>
#include <string>
#include <iostream>
#include <type.h>
using namespace std;
bool operator(string opr)
{
if (opr == “^” || opr == “*” || opr == “/” || opr == “+” opr == “-”)
{
return 1;
} else {
return 0;
}
}
string precedence (string a, string b)
{
string c = “sama”;
if
to be continued..
April 7, 2009
Oktober 10, 2009
Mei 7, 2009