hello everybody .... i need explaination for this program
i know what the program dose do but i didn't understand all statements in it


this program is to read from and write in floopy

#include "BS.H"

BOOL AbsRead(WORD,WORD,LPVOID);
WORD ReadFatEle(WORD);
WORD SearchFile(char *);

char FatEle[5120];
//FatEle is pointer to the first element of the array
WORD gFatSize;
WORD gRootSize;

struct RD
{
char NameFile[8];
char Ext[3];
char Reserved[10];//os
char Att;//attribute
WORD Time;
WORD Date;
WORD NumFirstClus;
DWORD Size;
};

int main()
{

char NameF[13];
BS BOOTSEC;
WORD FatElement;

if(AbsRead(0,1,&BOOTSEC)==FALSE)
{
cout<<"Reading boot sector Didn't Success...\n";
exit(EXIT_FAILURE);
}

gFatSize=BOOTSEC.FatSize;
gRootSize=(BOOTSEC.RootSize*32)/512;

if(AbsRead(1,gFatSize,FatEle)==FALSE)
{
cout<<"Reading fat elements by absread didn't success...\n";
exit(EXIT_FAILURE);
}
printf("Please Enter the Name of file :");
scanf("%12s",NameF);
strupr(NameF);

if((FatElement=SearchFile(NameF))==0)//
{
printf("The file isn't exist...\n");
exit(EXIT_FAILURE);
}

while(FatElement!=0xfff && FatElement!=0x0)
{
printf("%5hX",FatElement);//short hexa
FatElement=ReadFatEle(FatElement);

}
printf("\n");
return 0;
}

WORD SearchFile(char *NameF)
{
RD Buffer[16];

for(int i=0;i<=gRootSize;i++)//number of sectors for root directory
{
if(AbsRead(i+(gFatSize*2+1),1,Buffer)==FALSE)
{
cout<<"Cann't read sector number "<<i+1<<" From root directory...\n";
exit(EXIT_FAILURE);
}
for(int j=0;j<16;j++)
{
int NameLoop=0;
int ExtLoop=0;
char FoundName[13]={'\0'};
if(Buffer[j].NameFile[0]==' ' || Buffer[j].NameFile[0]==0xe5 || Buffer[j].Att==8)
continue;
while(Buffer[j].NameFile[NameLoop]!=' ' && NameLoop<8)
{
FoundName[NameLoop]=Buffer[j].NameFile[NameLoop];
NameLoop++;
}
if(Buffer[j].Ext[0]!=' ')
{
FoundName[NameLoop]='.';
NameLoop++;
while(Buffer[j].Ext[ExtLoop]!=' ' && ExtLoop<3)
{
FoundName[NameLoop]=Buffer[j].Ext[ExtLoop];
ExtLoop++;
NameLoop++;
}
}
if(strcmp(FoundName,NameF)==0)
return Buffer[j].NumFirstClus;
}
}
return 0;
}

BOOL AbsRead(WORD FirstSector,WORD NumSectors,LPVOID Buffer)
{
HANDLE H_disk;

H_disk=CreateFile("\\\\.\\a:",GENERIC_READ,FILE_SH ARE_READ,NULL,OPEN_EXISTING,NULL,NULL);

if(H_disk==INVALID_HANDLE_VALUE)
{
cout<<"Error:"<<GetLastError()<<endl;
return FALSE;
}
DWORD L_SET;
L_SET=SetFilePointer(H_disk,FirstSector*512,NULL,F ILE_BEGIN);
if(L_SET==0xfff)
{
cout<<"Error:"<<GetLastError()<<endl;
return FALSE;
}

DWORD BR;
if(!ReadFile(H_disk,Buffer,NumSectors*512,&BR,NULL ))//Readfile return BOOL
{
cout<<"Error:"<<GetLastError()<<endl;
return FALSE;
}
CloseHandle(H_disk);
return TRUE;
}

WORD ReadFatEle(WORD FatElement)
{
WORD i;
i=(FatElement*3)/2;
if(FatElement%2==0)
return (*((WORD*)(FatEle+i))&(0x0FFF));
else
return (*((WORD*)(FatEle+i))>>4);

}




//<BS.h>

#include <iostream.h>
#include <stdio.h>
#include <windows.h>
#include <winioctl.h>


struct BS
{
char JMP[3];//booting
char CmpName[8];//company name
WORD BytePerSector;
unsigned char ClusterSize;
WORD ReservedSector;//for os
char FatCount;//2
WORD RootSize;//number of entry 32
WORD TotalSector;
char MediaDes;
WORD FatSize;//9
char RemainByte[488];
};

//</BS.h>


Best regrads