Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Python create a column called number_of_days that represents the number of days that will be subtracted from another column called date. date column contains dates

Python

create a column called number_of_days that represents the number of days that will be subtracted from another column called "date". date column contains dates such as 2020-12-13, 2020-10-25 .

the new column number_of_days should have the number of days between today's date subtracted from date.

number_of_days = today's date - date

For example: lets say the first row in the "date" column is 2020-12-13

so the firs row in the new column "number_of_days " should be:

number_of_days = 2021-03-04 - 2020-12-13 = 81 days

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Systems On GPUs In Databases

Authors: Johns Paul ,Shengliang Lu ,Bingsheng He

1st Edition

1680838482, 978-1680838480

More Books

Students also viewed these Databases questions

Question

How can you defend against SQL injection attacks?

Answered: 1 week ago