Untitled Document
Calculate Number OF Days , Weeks or Months - Future Dates
1. In The Below example - we will calulate how many weeks it take to loose weight set as our goal Click Here
#********* Source Code From Website - Mangadaku - visit us at -http://mangadaku.com/ ***** 
# EX -1  In The Below example - we will calulate how many weeks it take to loose weight 
# set as our goal 

import datetime

current_weight = 220
goal_weight = 180
avg_lbs_week = 2

start_date = datetime.date.today()
end_date = start_date

while current_weight > goal_weight:
	end_date += datetime.timedelta(days=7)
	current_weight -= avg_lbs_week

print(end_date)
print(f'Reached goal in {(end_date - start_date).days // 7 } weeks')
       
2. Program - Caluclating Exact date to achive future date at which we ill get 10000 hits Click Here
#********* Source Code From Website - Mangadaku - visit us at -http://mangadaku.com/ *****      
# Program - Caluclating Exact date to achive future date at which we ill get 10000 hits

import datetime
import math 

goal_subs = 150000
current_subs = 85000
subs_to_go = goal_subs - current_subs

avg_subs_day = 200
days_to_go = math.ceil(subs_to_go / avg_subs_day)

today = datetime.date.today()
print(today + datetime.timedelta(days=days_to_go))

       
Untitled Document