18 lines
207 B
Plaintext
18 lines
207 B
Plaintext
![]() |
Chained assignments are confusing and hard to read, and should be avoided.
|
||
|
|
||
|
|
||
|
== Noncompliant Code Example
|
||
|
|
||
|
----
|
||
|
x = y = 0; // Noncompliant
|
||
|
----
|
||
|
|
||
|
|
||
|
== Compliant Solution
|
||
|
|
||
|
----
|
||
|
x = 0;
|
||
|
y = 0; // or y = x;
|
||
|
----
|
||
|
|