We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
If you're working with division in Python, make sure to use / for float division and // for integer division. For example, 5 / 2 returns 2.5 while 5 // 2 returns 2. You can find more practical examples and guides like this on websites such as VisaCheckQatar.
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Python: Division
You are viewing a single comment's thread. Return to all comments →
If you're working with division in Python, make sure to use / for float division and // for integer division. For example, 5 / 2 returns 2.5 while 5 // 2 returns 2. You can find more practical examples and guides like this on websites such as VisaCheckQatar.