The coexistence of various base stations (BSs) in heterogeneous networks (HetNets) has emerged as a promising approach to meet the ever increasing network capacity. In these networks, one of the important issues is the problem of associating user equipments (UEs) to BSs. In this paper, we investigate the UE association (UEA) problem in heterogeneous networks and propose a load-aware UEA mechanism based on the BSs' estimated load and signal-to-interference-and-noise ratio. The proposed mechanism can capture the trade-off between UE's quality-of-service requirement and delay. We model this strategic UE-BS association as a noncooperative game. To solve the game, we develop a fully distributed algorithm inspired by machine learning techniques, whereby the proposed UEA scheme corresponds to a Markov chain.In the proposed scheme, each UE senses its environment and decides which BS to select based on the satisfaction technique. Therefore, it achieves a high level of satisfaction for UEs. Furthermore, use of historical information helps UEs select BSs with better long-term performance. Simulation results show that the proposed mechanism reduces fractional transfer time and the number of unsatisfied UEs, respectively, up to about 46% and 52.3% and improves BS throughput up to about 15.4% compared to a benchmark algorithm that is based on the received signal strength and the BS's estimated load.