This paper proposes a Deep-Q-Network (DQN) controller for network selection and adaptive resource allocation in heterogeneous networks, developed on the ground of a Markov Decision Process (MDP) model of the problem. Network selection is an enabling technology for multi-connectivity, one of the core functionalities of 5G, and for this reason the present work considers a realistic network model that takes into account path-loss models and intra-RAT (Radio Access Technology) interference. Numerical simulations validate the proposed approach and show the improvements achieved thanks to the DQN algorithm with respect to a classic Reinforcement Learning algorithm and baseline approaches in terms of connection-flows' acceptance, resource allocation and load balancing.