used address operator for flag parsing to eliminate over-use of pointers in the rest of the code