Google C++ Style Guideappropriate, you are welcome to use standard types like size_t and ptrdiff_t. We use int very often, for integers we know are not going to be too big, e.g., loop counters. Use plain old int for such things. You that it has more than 32 bits. If you need a 64-bit integer type, use int64_t or uint64_t. For integers we know can be “big”, use int64_t. You should not use the unsigned integer types such as uint32_t integer types. Integer conversions and promotions can cause non-intuitive behavior. On Unsigned Integers Some people, including some textbook authors, recommend using unsigned types to represent numbers0 码力 | 83 页 | 238.71 KB | 1 年前3
 Google Python Style Guidefalse, so if not seq: or if seq: is preferable to if len(seq): or if not len(seq):. • When handling integers, implicit false may involve more risk than benefit (i.e., accidentally handling None as 0). You0 码力 | 30 页 | 94.81 KB | 1 年前3
共 2 条
- 1
 













