https://github.com/dragonxdev/c-calculator
https://github.com/dragonxdev/c-calculator
Last synced: about 1 year ago
JSON representation
- Host: GitHub
- URL: https://github.com/dragonxdev/c-calculator
- Owner: DragonXDev
- Created: 2025-01-25T21:54:46.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-01-25T21:57:02.000Z (over 1 year ago)
- Last Synced: 2025-01-25T22:38:21.357Z (over 1 year ago)
- Language: C
- Size: 0 Bytes
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Binary Calculator
A simple C-based calculator that performs basic arithmetic operations using bitwise operations.
## Features
- Addition (`+`)
- Subtraction (`-`)
- Multiplication (`*`)
- Division (`/`)
## Installation
1. Clone the repository:
```sh
git clone https://github.com/yourusername/binary-calculator.git
cd binary-calculator
```
2. Compile the project:
```sh
gcc -o bin_calculator main.c calculator.c -I.
```
## Usage
Run the calculator:
```sh
./bin_calculator
```
Example usage in C:
```c
#include
#include "calculator.h"
int main() {
int result = calculate(10, 5, '+');
printf("Result: %d\n", result);
return 0;
}
```
## Compilation & Running
To compile and run:
```sh
gcc -o bin_calculator main.c calculator.c -I.
./bin_calculator
```
## License
This project is licensed under the MIT License.