I am afraid that this is not good at all:
Code:
int an1,bb1,tm,i,mn1;
double in1;
double q1;
double qq1;
double qqq1;
double q2;
double q3;
double ad=0;
double aw=0;
int f1=1;
int f2;
int fo=1;
int yn=1;
int mn=1;
double z;
int ynl=1;
Keep in mind:
- Your variable names should be descriptive. This means names like account_number, not an1, and account_beginning_balance, not bb1. You should not have single letter variable names except for loop indices (in which case they would typically have a very limited scope, i.e., limited to the loop).
- Variables should be declared near first use. That is, declare variables at the point when you can initialise them suitably, or if you cannot initialise them per se, then at the point nearest to where you can otherwise provide them with a sensible initial value.
- If you are repeating the same name, but with numbers, then maybe you should consider using an array or some other suitable container.
Additionally, you should break up your main function into smaller functions that do one thing and do it well.
You also need to indent your code more consistently.