Skip to main content
Copy edited.
Source Link
Peter Mortensen
  • 31.4k
  • 22
  • 110
  • 134

They are both equallyequal - the same According.

According to the specsspecifications anything that is not 0 is considered true, so even without any optimization, and a good compiler will not generate any code for for while(1) or while(2) the. The compiler would generate a simple check for != 0!= 0.

They are both equally the same According to the specs anything that is not 0 is considered true so even without any optimization, and a good compiler will not generate any code for while(1) or while(2) the compiler would generate a simple check for != 0

They are both equal - the same.

According to the specifications anything that is not 0 is considered true, so even without any optimization, and a good compiler will not generate any code for while(1) or while(2). The compiler would generate a simple check for != 0.

Source Link

They are both equally the same According to the specs anything that is not 0 is considered true so even without any optimization, and a good compiler will not generate any code for while(1) or while(2) the compiler would generate a simple check for != 0