1const validBloodGroupRegex = /^(A|B|AB|O)[+-]$/i; // Here i is to ignore case sensitivity
2const validBloodGroupString = 'AB+';
3const invalidBloodGroupString = 'BC+';
4
5// Returns true
6console.log(validBloodGroupRegex.test(validBloodGroupString))
7
8// Returns false
9console.log(validBloodGroupRegex.test(invalidBloodGroupString))