Introduction To Python - Learn Python the hard way v2.0
Section: Exercise 4: Variables And Names
Activity: Please submit links to your blog posts related to this activity
http://twitter.com/trukise submitted this response ( Ex4 ) about Apr 13, 2012
0 voteup image
Reviews
This section contains reviews provided by the community for the activity response specified at the top of the page. Please use the form at the end to provide a constructive review of the activity.

@trukise, nice activity response.

In this case using 4 instead of 4.0 will not change the result. However, remember when you do a pure decimal operation, the result will also be in decimal.

2/4 => will give you 0 (because the floating point part is truncated)

2.0/4.0 => will give you 0.5

Please login to provide a review of this activity response