-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
822e012
commit bd1861b
Showing
2 changed files
with
24 additions
and
0 deletions.
There are no files selected for viewing
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# Lazy Math Instructor | ||
|
||
## Introduction | ||
This is my code for the proseminar [Selected Fun Problems of the ACM Programming Contest](https://db.cs.uni-tuebingen.de/teaching/ss23/acm-programming-contest-proseminar/) at the University of Tübingen, Summer Term 2023. | ||
|
||
The problem worked on is the [Lazy Math Instructor](./Lazy-Math-Instructor.pdf): The exercise is to check arbitrary terms for equivalence. | ||
Terms may contain brackets, addition, subtraction and multiplication of integer constants and variables `a` to `z`. | ||
|
||
They are evaluated from left to right with no operator precedence. | ||
|
||
## Usage of the program | ||
|
||
The program is written in C# .NET 7.0 and should run on any supported platform. | ||
|
||
Program reads from STDIN: | ||
- 1 line with the number `n` of equivalences to test | ||
- 2`n` lines with a term each. | ||
|
||
Program writes to STDOUT: | ||
- `n` lines, reading | ||
- `YES` if the `n`-th pair of terms are equivalent | ||
- `NO` if they aren't. | ||
|
||
Verbose mode can be enabled by passing `-v` as a command line argument, in which case the program will print each term after it was parsed, normalized and ordered deterministically. |