An open API service indexing awesome lists of open source software.

https://github.com/nsavinda/calc-parser

Simple calculator using flex and bison.
https://github.com/nsavinda/calc-parser

bison-flex bison-yacc compiler compiler-design parser

Last synced: about 1 month ago
JSON representation

Simple calculator using flex and bison.

Awesome Lists containing this project

README

          

# Calc

This project implements a simple calculator using flex and bison.

![Calculator](https://github.com/nsavinda/calc/blob/main/test.png)

## Building

To build the calculator, run the following command:

```bash
make
```

This will create an executable file named `calc`.

## Running

To run the calculator, type the following command:

```bash
./calc
```

You can then enter mathematical expressions at the prompt. The calculator will evaluate the expressions and print the results.

## Debugging

To build the calculator with debugging symbols, run the following command:

```bash
make debug
```

This will create an executable file named `calc` with debugging symbols. You can then use a debugger such as gdb to debug the calculator.

## Testing

To run the test suite, run the following command:

```bash
make test
```

This will run the test suite and print the results.

## Cleaning

To clean up the project, run the following command:

```bash
make clean
```

This will remove all of the generated files.