Skip to content

Yash14909/C_gcc-pgms

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation


# 🧠 C Programs Collection

A comprehensive collection of **C programs** created for learning, practice, and implementation of core programming concepts such as data structures, algorithms, file handling, and more.  
This repository is ideal for beginners, students, and anyone looking to strengthen their C programming skills.

---

## 📁 Repository Structure

The repository is organized by topic for easy navigation:

---

## ⚙️ How to Run

To compile and run any C program from this repository:

```bash
gcc filename.c -o output
./output

Or in Windows (using MinGW or Turbo C):

gcc filename.c -o output.exe
output.exe

🧩 Example

Here’s a simple example from the Basics section:

#include <stdio.h>

void addMatrices(int matrix1[3][3], int matrix2[3][3], int result[3][3]) {
    for (int i = 0; i < 3; i++) {
        for (int j = 0; j < 3; j++) {
            result[i][j] = matrix1[i][j] + matrix2[i][j];
        }
    }
}

void printMatrix(int matrix[3][3]) {
    for (int i = 0; i < 3; i++) {
        for (int j = 0; j < 3; j++) {
            printf("%d ", matrix[i][j]);
        }
        printf("\n");
    }
}

int main() {
    int matrix1[3][3] = {
        {1, 2, 3},
        {4, 5, 6},
        {7, 8, 9}
    };

    int matrix2[3][3] = {
        {9, 8, 7},
        {6, 5, 4},
        {3, 2, 1}
    };

    int result[3][3];
    addMatrices(matrix1, matrix2, result);

    printf("Resultant Matrix:\n");
    printMatrix(result);

    return 0;
}

Output:

Hello, World!

🧠 Learning Goals

This repository aims to:

  • Build a strong foundation in C programming.
  • Enhance problem-solving and algorithmic thinking.
  • Prepare for coding interviews and university exams.
  • Help others learn by exploring real examples.

🤝 Contributing

Contributions are welcome! If you’d like to add a new program or improve an existing one:

  1. Fork this repository
  2. Create a new branch (feature/new-program)
  3. Commit your changes
  4. Push the branch
  5. Open a Pull Request

🧾 License

This project is licensed under the MIT License — see the LICENSE file for details.


👥 Authors

  • [Yashvardhan Reddy] — Project Lead

🌟 Acknowledgements

Special thanks to:


⭐ Don’t forget to Star this repository if you find it helpful!


---

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages