BloodMatch Validator
A robust command-line utility for comprehensive blood group validation and donation compatibility checking. This program is a core demonstration of implementing complex, nested logical control flow (if-else, else if, &&, || operations) for precise, real-world decision-making.
Functionality Overview
The BloodMatch Validator performs a dual role:
1. Input Validation: It accepts two string inputs—the potential Receiver's blood group and the Donor's blood group. It performs a case-insensitive check to ensure both inputs are recognized human blood groups (A, B, AB, O, with positive/negative Rh factor). The program clearly identifies and reports which input, if any, is invalid.
2. Donation Compatibility Check: If both inputs are verified as valid, the program executes the complex logic required to determine and report the precise donation outcome: whether the Receiver's blood can be safely donated to the Donor's group.
This utility is perfect for illustrating practical application of string handling and Boolean logic in any programming language.