“One man’s law is another man’s crime. Sleep on it Chesterton, sleep on it.” The Doctor, the Edge of Destruction.
What we love about this particular moment is that the Doctor has told Ian that for Ian to be able to do anything productive he has to listen to him because he’s always one step ahead and full of knowledge which will lead to the best results. Ian of course wants to know the kind of results the Doctor is referring to as in Ian’s mind not all knowledge is used for good. The Doctor responds with his usual dismissive nature.
It relates back to when the Doctor told Barbara that she was judging him based on her standards back on Earth. Here the Doctor is saying that culture and attitudes change depending on how you look at things and where you’re from. Things aren’t always so easy as saying something is right or wrong. The Doctor is not a human and his actions may easily be seen as a crime to humanity but could very well be the ‘law’ where he came from. In the first few serials, the Doctor is very different from humans and dislikes being made to adhere to human morality like he is on trial for his own way of doing things.