General goal: you are asked to design a web application, using which the users can check whether a credit card number is a fraud.
Resources: you are given a remote database that stores the list of fraud credit card numbers, you can read the data from the remote database. By "remote" here it means that the database is located in some other server that you have no control with: you can only read the data from the database, but you can not do anything with the database such as configuring the database or update the data in the database.
Use case: a user enter a credit card number on the website, and the website returns true if the input number is a fraud. That is, if the input number is in the remote database, then it is a fraud, otherwise it is not a fraud. As an example, suppose the user enters 123456, and the list of numebrs in the remote database is [123456,234567,345678], then you return true to the user.
Problem: you can't query the remote database everytime you get a new input from the user, because this will result in high latency. How would you design your application? You'll need to guarantee the consistency of the data.