addition: postfix operator capability, may work

This commit is contained in:
2026-05-12 19:40:42 -06:00
parent e30b3d7175
commit 7f390a8c6b
3 changed files with 54 additions and 3 deletions

View File

@@ -155,6 +155,9 @@ Operator char_to_operator(int c) {
case '^':
return OP_POW;
break;
case '!':
return OP_FACTORIAL;
break;
default: // I mean shouldn't be used, we assume
return -1;
}
@@ -172,5 +175,9 @@ char operator_to_char(Operator op) {
return '/';
case OP_POW:
return '^';
case OP_FACTORIAL:
return '!';
default:
return EOF;
}
}