/Operating-System-Lab

๐Ÿ’ป OS Lab Programs in C | CPU Scheduling, Memory Management, IPC, Deadlocks | Well-documented & beginner-friendly

Primary LanguageC

๐Ÿงช Operating Systems Lab โ€“ Open Source Repository

Welcome to the Operating Systems Lab open-source repository!
This project contains clean, beginner-friendly C implementations of core OS concepts taught in university labs such as VTU, Anna University, and others.

โœจ Made by students, for students. Learn by doing, and contribute as you grow.


๐Ÿ“š Contents

Category Folder Algorithms / Programs Included
CPU Scheduling scheduling/ FCFS, SJF, Round Robin, Priority
Memory Management memory_management/ First Fit, Best Fit, Worst Fit
Page Replacement page_replacement/ FIFO, LRU
Deadlock Avoidance deadlock/ Banker's Algorithm
Interprocess Comm. ipc/ Producer-Consumer, Reader-Writer

๐Ÿ› ๏ธ How to Run

Each program is written in C and can be compiled using gcc:

gcc filename.c -o outputname
./outputname

Some programs use pthreads:

gcc thread_based_file.c -lpthread -o program

๐Ÿ’ป Example Projects

  • โœ… scheduling/fcfs/fcfs.c: First Come First Serve CPU scheduling
  • โœ… ipc/producer_consumer.c: Synchronization using semaphores
  • โœ… deadlock/bankers_algorithm.c: Avoid deadlocks using Banker's safety algorithm

๐Ÿ“š Recommended Learning Resources


๐Ÿง‘โ€๐Ÿ’ป Contributing

Want to improve this repo?

  1. ๐Ÿด Fork this repo
  2. ๐Ÿ“ฅ Clone your fork
  3. ๐Ÿ› ๏ธ Make your changes
  4. ๐Ÿ“ค Submit a Pull Request

Contributions can include:

  • New algorithms
  • Gantt chart visuals
  • Bug fixes or cleaner explanations
  • Translations or language ports (Python/Java)

๐Ÿ“ License

This project is released under the MIT License โ€“ free to use, modify, and contribute.


๐Ÿ™Œ Credits

Thanks to all contributors, batchmates, and the open-source OS community! ๐Ÿ’™