Banker's algorithm is a resource allocation and deadlock avoidance algorithm which is modeled after the lending policies employed in a banking system.
The banker's algorithm must determine whether allocation of the resources will put tihe system in a safe state or not.