⭐️ Star this repository! It really motivates me to make better explanations and produce more work!! ⭐️
This repository contains several C programs that implement different functionalities and algorithms:
inheritance.c
- A program that simulates genetic inheritance of blood types.speller.c
- A program that implements a spell checker using a hash table.dictionary.c
- A program that provides dictionary functionalities using a hash table.
The inheritance.c
program simulates the inheritance of blood types through multiple generations. It constructs a family tree and assigns blood type alleles randomly.
- Creates a family tree with a specified number of generations.
- Randomly assigns blood type alleles to individuals.
- Prints the family tree with the assigned blood types.
- Simulates genetic inheritance using random allele assignment.
- Constructs and displays a family tree structure.
- Utilizes basic data structures and random number generation.
The speller.c
program implements a spell checker that uses a hash table to check if words are correctly spelled based on a dictionary. It also benchmarks various operations.
- Loads a dictionary into memory using a hash table.
- Reads and checks each word in the input text file.
- Reports misspelled words and provides benchmarking results.
- Utilizes hash table for efficient word checking.
- Benchmarks dictionary loading, word checking, and unloading.
- Handles file input/output and memory management.
The dictionary.c
program implements basic dictionary functionalities using a hash table. It includes operations to load, check, size, and unload a dictionary.
- Loads words from a dictionary file into a hash table.
- Provides functionality to check if words are in the dictionary.
- Calculates the number of words and unloads the dictionary from memory.
- Implements hash table for dictionary operations.
- Handles file reading and memory management.
- Provides essential dictionary functionalities.
This project was inspired by and developed as part of the CS50x course offered by Harvard University. CS50x is Harvard University's introduction to the intellectual enterprises of computer science and the art of programming for majors and non-majors alike, with or without prior programming experience.
Thank you to the CS50x team for providing such a comprehensive and engaging introduction to computer science. |