python //What does it mean?

藏色散人
Release: 2020-05-25 09:54:19
Original
8893 people have browsed it

python //What does it mean?

python //What does it mean?

In Python " // " represents integer division.

X // Y
Copy after login

//The effect of the operation is the same for Python2. For point calculation, the result will still be returned in the form of a floating point number, such as -5.0 // 2, the result is -3.0:

Recommended: "python tutorial"

-5 // 2
#2.X 商:-3 余数:1
#3.X 商:-3 余数:1
#C 商:-2 余数:-1
-5.0 // 2
#2.X 商:-3.0 余数:1.0
#3.X 商:-3.0 余数:1.0
#C 商:-2.5 余数:C的取余运算不支持浮点数
Copy after login

The above is the detailed content of python //What does it mean?. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!