??? 09/20/06 17:12 Read: times |
#124695 - what an utterly stupid teacher Responding to: ???'s previous message |
As my Pascal teacher said. If you use Globals you get an F, unless you can demonstrate there is not other way.
what an utterly stupid teacher. You do not give an F for such, that is making "the rule" more important than the product. Were I the teacher (fear not) I would say "If you use Globals you get a lower grade, unless you can demonstrate an advantage of doing so" I shall not mention the company name, but the code in a popular cellphone has no globals because of a management decision of "no globals". However in main() it has a giant structure the pointer to which is transferred all over the place and the contents of that structure is modified whenever it is deemed necessary to do so. But, of course, the code has no "global variables". This is an example of the stupid rule being implemented for the sake of "the rule". Erik |