We show that wave dynamics in nanostructured media can perform artificial neural computing, and artificial neural network can also be used to design nanophotonic media.