How to calculate age how were born in leap year
up vote
1
down vote
favorite
I was born in leap year 2000.
How to calculate my age from 2000? And I need formula to calculate my age please help to calculate my age?
python-3.x
add a comment |
up vote
1
down vote
favorite
I was born in leap year 2000.
How to calculate my age from 2000? And I need formula to calculate my age please help to calculate my age?
python-3.x
add a comment |
up vote
1
down vote
favorite
up vote
1
down vote
favorite
I was born in leap year 2000.
How to calculate my age from 2000? And I need formula to calculate my age please help to calculate my age?
python-3.x
I was born in leap year 2000.
How to calculate my age from 2000? And I need formula to calculate my age please help to calculate my age?
python-3.x
python-3.x
edited Nov 11 at 13:15
Mayank Porwal
3,1651620
3,1651620
asked Nov 11 at 9:43
L. Aravind Kalaimani
62
62
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
up vote
0
down vote
In [1756]: from datetime import date
In [1757]: born = date(2000, 1, 1) # Assuming you were born on 1 Jan 2000
In [1759]: today = datetime.date.today()
In [1763]: age = today - born
You can tweak your born date. This gives you age in days.
OR
You can do below for age in years:
from dateutil.relativedelta import relativedelta
born = date(2000,3,18) # You were born on 18th Mar 2000
today = datetime.date.today()
age = relativedelta(today, born).years
In [1770]: age
Out[1770]: 18
Mayank porwal madam please help me to I was born in March 18 .03.2000 leap day and leap year what is my age 17or18? Please reply to this question madam
– L. Aravind Kalaimani
Nov 11 at 9:52
@L.AravindKalaimani Check my updated answer. Your age will be18.
– Mayank Porwal
Nov 11 at 9:55
Mayank Porwal madam I had see your answer thank for replying I have one more confusion my date of birth is 18.03.2000 I had search for lot in google for this problem by searching that I have see one information madam it is correct or wrong I do know march 18 is the 77th day of the year (78th leap years in the Gregorian clander there are 288 days remaining until the end of the year I have also read one formula we should not clacute our age from date of birth year we should subtract our age when we became 1 year old we should subtract when become 1 year old from current year please help me madam
– L. Aravind Kalaimani
Nov 11 at 10:25
Madam please help me to slove this problem I have studied only 8 Std I openly saying my problem madam please do not say we can not help in this kind of problem in this website I had questions more than 10 but know repsone I had ask about this problem they have said your in drepssion go and see the doctor we can not help in this kind of problem we are not doctors they are saying I am sorry they are saying the truth I will understand but they are not question my answer I am little weak in English I know write to English and read English but I do know how to speak
– L. Aravind Kalaimani
Nov 11 at 10:31
Madam I my life I have faced lot of problems and struggle in my life I am so fat and height for that people are teacing and and all people are using as comedy piece if they anger they will show to me in my family I have fear In school time all classmates tease me and keep on torture me using bad word do and die Than I will cry students doing this like means my class teacher also supports if they do wrong and mistake he not ask them he scold me and pushie me all teachers will trouture me it big International school all rich people children will study there
– L. Aravind Kalaimani
Nov 11 at 10:37
|
show 1 more comment
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
0
down vote
In [1756]: from datetime import date
In [1757]: born = date(2000, 1, 1) # Assuming you were born on 1 Jan 2000
In [1759]: today = datetime.date.today()
In [1763]: age = today - born
You can tweak your born date. This gives you age in days.
OR
You can do below for age in years:
from dateutil.relativedelta import relativedelta
born = date(2000,3,18) # You were born on 18th Mar 2000
today = datetime.date.today()
age = relativedelta(today, born).years
In [1770]: age
Out[1770]: 18
Mayank porwal madam please help me to I was born in March 18 .03.2000 leap day and leap year what is my age 17or18? Please reply to this question madam
– L. Aravind Kalaimani
Nov 11 at 9:52
@L.AravindKalaimani Check my updated answer. Your age will be18.
– Mayank Porwal
Nov 11 at 9:55
Mayank Porwal madam I had see your answer thank for replying I have one more confusion my date of birth is 18.03.2000 I had search for lot in google for this problem by searching that I have see one information madam it is correct or wrong I do know march 18 is the 77th day of the year (78th leap years in the Gregorian clander there are 288 days remaining until the end of the year I have also read one formula we should not clacute our age from date of birth year we should subtract our age when we became 1 year old we should subtract when become 1 year old from current year please help me madam
– L. Aravind Kalaimani
Nov 11 at 10:25
Madam please help me to slove this problem I have studied only 8 Std I openly saying my problem madam please do not say we can not help in this kind of problem in this website I had questions more than 10 but know repsone I had ask about this problem they have said your in drepssion go and see the doctor we can not help in this kind of problem we are not doctors they are saying I am sorry they are saying the truth I will understand but they are not question my answer I am little weak in English I know write to English and read English but I do know how to speak
– L. Aravind Kalaimani
Nov 11 at 10:31
Madam I my life I have faced lot of problems and struggle in my life I am so fat and height for that people are teacing and and all people are using as comedy piece if they anger they will show to me in my family I have fear In school time all classmates tease me and keep on torture me using bad word do and die Than I will cry students doing this like means my class teacher also supports if they do wrong and mistake he not ask them he scold me and pushie me all teachers will trouture me it big International school all rich people children will study there
– L. Aravind Kalaimani
Nov 11 at 10:37
|
show 1 more comment
up vote
0
down vote
In [1756]: from datetime import date
In [1757]: born = date(2000, 1, 1) # Assuming you were born on 1 Jan 2000
In [1759]: today = datetime.date.today()
In [1763]: age = today - born
You can tweak your born date. This gives you age in days.
OR
You can do below for age in years:
from dateutil.relativedelta import relativedelta
born = date(2000,3,18) # You were born on 18th Mar 2000
today = datetime.date.today()
age = relativedelta(today, born).years
In [1770]: age
Out[1770]: 18
Mayank porwal madam please help me to I was born in March 18 .03.2000 leap day and leap year what is my age 17or18? Please reply to this question madam
– L. Aravind Kalaimani
Nov 11 at 9:52
@L.AravindKalaimani Check my updated answer. Your age will be18.
– Mayank Porwal
Nov 11 at 9:55
Mayank Porwal madam I had see your answer thank for replying I have one more confusion my date of birth is 18.03.2000 I had search for lot in google for this problem by searching that I have see one information madam it is correct or wrong I do know march 18 is the 77th day of the year (78th leap years in the Gregorian clander there are 288 days remaining until the end of the year I have also read one formula we should not clacute our age from date of birth year we should subtract our age when we became 1 year old we should subtract when become 1 year old from current year please help me madam
– L. Aravind Kalaimani
Nov 11 at 10:25
Madam please help me to slove this problem I have studied only 8 Std I openly saying my problem madam please do not say we can not help in this kind of problem in this website I had questions more than 10 but know repsone I had ask about this problem they have said your in drepssion go and see the doctor we can not help in this kind of problem we are not doctors they are saying I am sorry they are saying the truth I will understand but they are not question my answer I am little weak in English I know write to English and read English but I do know how to speak
– L. Aravind Kalaimani
Nov 11 at 10:31
Madam I my life I have faced lot of problems and struggle in my life I am so fat and height for that people are teacing and and all people are using as comedy piece if they anger they will show to me in my family I have fear In school time all classmates tease me and keep on torture me using bad word do and die Than I will cry students doing this like means my class teacher also supports if they do wrong and mistake he not ask them he scold me and pushie me all teachers will trouture me it big International school all rich people children will study there
– L. Aravind Kalaimani
Nov 11 at 10:37
|
show 1 more comment
up vote
0
down vote
up vote
0
down vote
In [1756]: from datetime import date
In [1757]: born = date(2000, 1, 1) # Assuming you were born on 1 Jan 2000
In [1759]: today = datetime.date.today()
In [1763]: age = today - born
You can tweak your born date. This gives you age in days.
OR
You can do below for age in years:
from dateutil.relativedelta import relativedelta
born = date(2000,3,18) # You were born on 18th Mar 2000
today = datetime.date.today()
age = relativedelta(today, born).years
In [1770]: age
Out[1770]: 18
In [1756]: from datetime import date
In [1757]: born = date(2000, 1, 1) # Assuming you were born on 1 Jan 2000
In [1759]: today = datetime.date.today()
In [1763]: age = today - born
You can tweak your born date. This gives you age in days.
OR
You can do below for age in years:
from dateutil.relativedelta import relativedelta
born = date(2000,3,18) # You were born on 18th Mar 2000
today = datetime.date.today()
age = relativedelta(today, born).years
In [1770]: age
Out[1770]: 18
edited Nov 11 at 9:52
answered Nov 11 at 9:50
Mayank Porwal
3,1651620
3,1651620
Mayank porwal madam please help me to I was born in March 18 .03.2000 leap day and leap year what is my age 17or18? Please reply to this question madam
– L. Aravind Kalaimani
Nov 11 at 9:52
@L.AravindKalaimani Check my updated answer. Your age will be18.
– Mayank Porwal
Nov 11 at 9:55
Mayank Porwal madam I had see your answer thank for replying I have one more confusion my date of birth is 18.03.2000 I had search for lot in google for this problem by searching that I have see one information madam it is correct or wrong I do know march 18 is the 77th day of the year (78th leap years in the Gregorian clander there are 288 days remaining until the end of the year I have also read one formula we should not clacute our age from date of birth year we should subtract our age when we became 1 year old we should subtract when become 1 year old from current year please help me madam
– L. Aravind Kalaimani
Nov 11 at 10:25
Madam please help me to slove this problem I have studied only 8 Std I openly saying my problem madam please do not say we can not help in this kind of problem in this website I had questions more than 10 but know repsone I had ask about this problem they have said your in drepssion go and see the doctor we can not help in this kind of problem we are not doctors they are saying I am sorry they are saying the truth I will understand but they are not question my answer I am little weak in English I know write to English and read English but I do know how to speak
– L. Aravind Kalaimani
Nov 11 at 10:31
Madam I my life I have faced lot of problems and struggle in my life I am so fat and height for that people are teacing and and all people are using as comedy piece if they anger they will show to me in my family I have fear In school time all classmates tease me and keep on torture me using bad word do and die Than I will cry students doing this like means my class teacher also supports if they do wrong and mistake he not ask them he scold me and pushie me all teachers will trouture me it big International school all rich people children will study there
– L. Aravind Kalaimani
Nov 11 at 10:37
|
show 1 more comment
Mayank porwal madam please help me to I was born in March 18 .03.2000 leap day and leap year what is my age 17or18? Please reply to this question madam
– L. Aravind Kalaimani
Nov 11 at 9:52
@L.AravindKalaimani Check my updated answer. Your age will be18.
– Mayank Porwal
Nov 11 at 9:55
Mayank Porwal madam I had see your answer thank for replying I have one more confusion my date of birth is 18.03.2000 I had search for lot in google for this problem by searching that I have see one information madam it is correct or wrong I do know march 18 is the 77th day of the year (78th leap years in the Gregorian clander there are 288 days remaining until the end of the year I have also read one formula we should not clacute our age from date of birth year we should subtract our age when we became 1 year old we should subtract when become 1 year old from current year please help me madam
– L. Aravind Kalaimani
Nov 11 at 10:25
Madam please help me to slove this problem I have studied only 8 Std I openly saying my problem madam please do not say we can not help in this kind of problem in this website I had questions more than 10 but know repsone I had ask about this problem they have said your in drepssion go and see the doctor we can not help in this kind of problem we are not doctors they are saying I am sorry they are saying the truth I will understand but they are not question my answer I am little weak in English I know write to English and read English but I do know how to speak
– L. Aravind Kalaimani
Nov 11 at 10:31
Madam I my life I have faced lot of problems and struggle in my life I am so fat and height for that people are teacing and and all people are using as comedy piece if they anger they will show to me in my family I have fear In school time all classmates tease me and keep on torture me using bad word do and die Than I will cry students doing this like means my class teacher also supports if they do wrong and mistake he not ask them he scold me and pushie me all teachers will trouture me it big International school all rich people children will study there
– L. Aravind Kalaimani
Nov 11 at 10:37
Mayank porwal madam please help me to I was born in March 18 .03.2000 leap day and leap year what is my age 17or18? Please reply to this question madam
– L. Aravind Kalaimani
Nov 11 at 9:52
Mayank porwal madam please help me to I was born in March 18 .03.2000 leap day and leap year what is my age 17or18? Please reply to this question madam
– L. Aravind Kalaimani
Nov 11 at 9:52
@L.AravindKalaimani Check my updated answer. Your age will be
18.– Mayank Porwal
Nov 11 at 9:55
@L.AravindKalaimani Check my updated answer. Your age will be
18.– Mayank Porwal
Nov 11 at 9:55
Mayank Porwal madam I had see your answer thank for replying I have one more confusion my date of birth is 18.03.2000 I had search for lot in google for this problem by searching that I have see one information madam it is correct or wrong I do know march 18 is the 77th day of the year (78th leap years in the Gregorian clander there are 288 days remaining until the end of the year I have also read one formula we should not clacute our age from date of birth year we should subtract our age when we became 1 year old we should subtract when become 1 year old from current year please help me madam
– L. Aravind Kalaimani
Nov 11 at 10:25
Mayank Porwal madam I had see your answer thank for replying I have one more confusion my date of birth is 18.03.2000 I had search for lot in google for this problem by searching that I have see one information madam it is correct or wrong I do know march 18 is the 77th day of the year (78th leap years in the Gregorian clander there are 288 days remaining until the end of the year I have also read one formula we should not clacute our age from date of birth year we should subtract our age when we became 1 year old we should subtract when become 1 year old from current year please help me madam
– L. Aravind Kalaimani
Nov 11 at 10:25
Madam please help me to slove this problem I have studied only 8 Std I openly saying my problem madam please do not say we can not help in this kind of problem in this website I had questions more than 10 but know repsone I had ask about this problem they have said your in drepssion go and see the doctor we can not help in this kind of problem we are not doctors they are saying I am sorry they are saying the truth I will understand but they are not question my answer I am little weak in English I know write to English and read English but I do know how to speak
– L. Aravind Kalaimani
Nov 11 at 10:31
Madam please help me to slove this problem I have studied only 8 Std I openly saying my problem madam please do not say we can not help in this kind of problem in this website I had questions more than 10 but know repsone I had ask about this problem they have said your in drepssion go and see the doctor we can not help in this kind of problem we are not doctors they are saying I am sorry they are saying the truth I will understand but they are not question my answer I am little weak in English I know write to English and read English but I do know how to speak
– L. Aravind Kalaimani
Nov 11 at 10:31
Madam I my life I have faced lot of problems and struggle in my life I am so fat and height for that people are teacing and and all people are using as comedy piece if they anger they will show to me in my family I have fear In school time all classmates tease me and keep on torture me using bad word do and die Than I will cry students doing this like means my class teacher also supports if they do wrong and mistake he not ask them he scold me and pushie me all teachers will trouture me it big International school all rich people children will study there
– L. Aravind Kalaimani
Nov 11 at 10:37
Madam I my life I have faced lot of problems and struggle in my life I am so fat and height for that people are teacing and and all people are using as comedy piece if they anger they will show to me in my family I have fear In school time all classmates tease me and keep on torture me using bad word do and die Than I will cry students doing this like means my class teacher also supports if they do wrong and mistake he not ask them he scold me and pushie me all teachers will trouture me it big International school all rich people children will study there
– L. Aravind Kalaimani
Nov 11 at 10:37
|
show 1 more comment
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53247472%2fhow-to-calculate-age-how-were-born-in-leap-year%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown