Question 65739
Each level is 2^x (because each person has two parents and so forth.) 
Therefore, 
YOU are 2^0 = 1 (person); 
PARENTS are 2^1= 2 (people); 
GRANDPARENTS are 2^2= 4 (people); 
GREAT GRANDPARENTS are 2^3=8; 
GREAT GREAT GRANDPARENTS are 2^4=16; 
GREAT GREAT GREAT GRANDPARENTS are 2^5=32; 
and so forth. 
But notice that three "greats" implies 2^5. 
This means that x "greats" implies x+2. Therefore, 40 "greats" implies 2^42, which is the total number of people that you are considering. 
Also, the question is a bit unclear as to if you want to know the total number of people including yourself and parents, and grandparents, and so forth until great*40 grandparents, so if you include ALL of those people, then it will be 2^42+2^41+2^40+...+2^20+2^19+...+2^3+2^2+2^1+2^0 and so forth. 
<marquee>and so forth</marquee>
<marquee behavior="alternate">ntnk</marquee>