Created
February 21, 2021 11:06
-
-
Save aliaramli/df5f65c77a69c1c5ae9b20cadae15285 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var delivery_rate = 0.8; | |
var delivery_charge = 3; | |
if (distance_in_kilo >3){ | |
delivery_charge = distance_in_kilo * delivery_rate; | |
delivery_charge = Math.round(delivery_charge.toFixed(2)*10)/10; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment