Advertisement
2002ASP Coding Standards #6932

SIMPLE way to reverse the value of a Boolean field

This is an extremely easy method of reversing the value of a Boolean value.

AI

สรุปโดย AI: This codebase represents a historical implementation of the logic described in the metadata. Our preservation engine analyzes the structure to provide context for modern developers.

ซอร์สโค้ด
original-source
<font face="tahoma,verdana,helveica,arial" size=2 style="font-size: 8pt;">
If you have ever done this:<BR><BR>
IF someBoolean = TRUE THEN<BR>
   someBoolean = FALSE<BR>
ELSE<BR>
   someBoolean = TRUE<BR>
END IF<BR><BR>
Here's an easier method:<BR><BR>
someBoolean = NOT someBoolean.<BR><BR>
That's it... vote if you like.<BR><BR>
- Derreck
</font>
ความคิดเห็นดั้งเดิม (3)
กู้คืนจาก Wayback Machine