Skip to content

gobbcuh/come-and-git-it

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🎯 Simple Calculator Exercise

This repository was created as part of my learning journey in using Git and GitHub, following a workshop on YouTube entitled "Come and Git It." It includes a simple calculator program written in the C programming language.


🛠️ Purpose

The main purpose of this repository is to practice:

  • 🌀 Initializing a Git repository
  • ✍️ Writing and committing code
  • 📤 Pushing a project to GitHub
  • 🧩 Understanding the basics of version control

🖩 About the Program

This calculator program is extremely basic and was created as part of the workshop. It performs simple operations such as:

  • ➕ Addition
  • ➖ Subtraction
  • ✖️ Multiplication
  • ➗ Division

Note: This program is not intended to be a fully-featured calculator but rather serves as an exercise to demonstrate GitHub workflows.


🚀 How to Use

Option 1: Using the Terminal or Command Prompt

  1. Clone the repository to your local machine. Open your terminal (on Linux/Mac) or command prompt (on Windows) and run:
    git clone <repository-url>
  2. Navigate to the directory containing the program:
    cd <repository-folder-name>
  3. Compile the program using the GCC compiler (ensure GCC is installed):
    gcc calculator.c -o calculator
  4. Run the program:
    ./calculator

Note: If you're on Windows, use tools like Git Bash or WSL (Windows Subsystem for Linux). Alternatively, any terminal with a GCC-compatible environment will work.


Option 2: Using Visual Studio (Windows)

  1. Open Visual Studio and create a new project.
  2. Select Empty Project and name it (e.g., SimpleCalculator).
  3. Copy and paste the calculator.c file into the Source Files folder in the Solution Explorer.
  4. Right-click the project name in Solution Explorer and choose Set as Startup Project.
  5. Build and run the project by pressing Ctrl + F5.

Option 3: Using an IDE (e.g., Code::Blocks, Dev-C++, CLion)

  1. Open your preferred IDE and create a new project.
  2. Import or add the calculator.c file to the project.
  3. Build the project using the IDE's Build or Compile option.
  4. Run the project from the IDE.

🙌 Acknowledgments

A big thanks to Ms. Darla David, the creator of the YouTube workshop, for providing a beginner-friendly guide to Git and GitHub. You may visit the workshop to follow along and learn how to commit and push projects to GitHub yourself! 🌟

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages