JP Morgan Interview QuestionJava Developers
- 0of 0 votes
Design a rules engine. It should run in at least linear time and should efficiently handle repetitive attributes in different rules. E.g.,
1. Digit check
2. Character check
1. Rule 1 - input should be digit
2. Rule 2 - input should be digit and = 3
3. Rule 3 - input should be digit and between 2 and 5
4. Rule 4 - input should be character and value should be 'A'
5. Rule 5 - input should be character and value should be 'B'
Design rule matrix and process a stream of inputs. More than one rule may be applicable for a given input.
Interview Type: Phone Interview