I'd agree with Lenny. Avoid global variables at all costs.
Making code readable is a matter of opinion, so be flexible and consider input from others. I worked with someone who insisted on using Hungarian Notation once and his code was freaking impossible to read. (As an aside, the project we were working on had a massive code base written by west coast acid casualties and no-one really understood it - it took me two weeks to change one input text box to make it Y2K safe. The moral is, always get your code reviewed if possible and include readability as one of the aspects to be covered by the review).
This is the problem, I've never had anyone review my code. I've just come to realise how shit it is. so started to do things differently with new code I've written and look up some "best practices". It's tough though as my code is basically a massive hack. It's a combination of BASH doing some output organization and renaming, and string manipulation (FORTRAN is a bit long winded for string manipulation unless you write your own libraries) and FORTRAN. I'm basically a reasonably competent FORTAN hacker. i.e fucking useless.
This is the problem, I've never had anyone review my code. I've just come to realise how shit it is. so started to do things differently with new code I've written and look up some "best practices". It's tough though as my code is basically a massive hack. It's a combination of BASH doing some output organization and renaming, and string manipulation (FORTRAN is a bit long winded for string manipulation unless you write your own libraries) and FORTRAN. I'm basically a reasonably competent FORTAN hacker. i.e fucking useless.