How To Write Algorithm For Python Program