Number of days between two dates:

a) Shell

_$: echo $(( ( $(date -d "2014-02-01" "+%s") - $(date -d "2013-08-26" "+%s") ) / 86400))
159

b) Python

_$: python -c 'from datetime import date; print(date(2014, 2, 1) - date(2013, 8, 26)).days'
159

A date N days after another date:

a) Shell

_$: date -d "2015-12-15 180 days"
dom jun 12 00:00:00 CEST 2016

_$: date -d "2015-12-15 180 days" +%Y-%m-%d
2016-06-12

b) Python

_$: python -c 'from datetime import date, timedelta; print(date(2015, 12, 15) + timedelta(180))'
2016-06-12