Skip to content

Latest commit

 

History

History
38 lines (21 loc) · 611 Bytes

CppOperatorDivideAssign.md

File metadata and controls

38 lines (21 loc) · 611 Bytes

 

 

 

 

 

 

operator/= is the operator to divide a variable's value by a certain value, without making a copy.

 


#include <cassert> int main() {   double x = 1.0;   x/=5.0;   assert(x == 0.2); }