Emergent learning transforms a disordered optical medium into a photonic device capable of storage, recognition, and classification of arbitrary memory patterns. First, we show that the intensity at the output of a multiply scattering system can be described by a dyadic matrix, the optical-synaptic matrix, exhibiting the same form as a Hebbian synaptic matrix containing a single memory. Then, we employ emergent learning - an approach inspired by neuroscience - to exploit the vast dictionary of raw memories inherently available within a disordered optical structure, thereby engineering the optical-synaptic matrix to store a user-defined attractor, or tailored memory. Importantly these photonic structures also works as an optical comparators providing an intensity-based measure of the degree of similitude between a query pattern and the stored pattern, realizing an hardware co-localization between memory and optical operator. Our system has an almost infinite hardware capacity of tailored memories/ operators ($\mathcal{M} \sim 10^{60557}$), thus these tailored memories can be then employed as examples to build a classifier hardware based on intensity comparison without the need of additional digital transformation layers. Remarkably, this Photonic Emergent Learning platform is not only flexible and fabrication-free, but also relies primarily on analog processes, thus shifting the computational burden of training from the digital layers to the optical domain reducing the computational cost and enhancing performance.