We must take special care while naming the variable else it will lead to mystification.
Let us consider the following two code snippets
k = i*j;
printf(“area of rectangle = %d”,k);
int base=3,height=5, rect_area=0;
rect_area = base*height;
printf(“area of rectangle = %d”,rect_area);
The above two programs used to find the area of rectangle. However which one of it gives more meaning?
Do the variables (i,j,k) in Code 1 give any sort of meaning? They lead to confusion, don’t they?
Where as the variables (base, height, rect_area) in Code 2 give us more meaning than the Code 1.
So always try to give meaningful names to the variable.
Sahaya Darcius P