Effective Learning for Autonomous Robots by Individuals or an Environment