Is there some mathematical relation or formula that can estimate a better source code from a less better one?
If I write a program to do exactly the same task using PHP and PERL programming language, for example generating HTML with the text "Hello World!", can these two source code files be evaluated to conclude one is better than the other? The evaluation criteria can be anything. But I am looking for non-naive criteria.