Delphi-PRAXiS

Delphi-PRAXiS (https://www.delphipraxis.net/forum.php)
-   Delphi-News aus aller Welt (https://www.delphipraxis.net/58-delphi-news-aus-aller-welt/)
-   -   XOR swap/exchange: nowadays an almost extinct means to exchange two distinct variable (https://www.delphipraxis.net/178145-xor-swap-exchange-nowadays-almost-extinct-means-exchange-two-distinct-variable.html)

DP News-Robot 19. Dez 2013 16:30

XOR swap/exchange: nowadays an almost extinct means to exchange two distinct variable
 
Almost a year ago, a thread on “premature Delphi optimization” came by on G+ about this code: procedure ExchangeInteger(var AValue1, AValue2: Integer); begin AValue1 := AValue1 xor AValue2; AValue2 := AValue1 xor AValue2; AValue1 := AValue1 xor AValue2; end; I don’t think ...http://feeds.feedburner.com/~r/delph...~4/ZISBXLPzIVw

More...


Alle Zeitangaben in WEZ +1. Es ist jetzt 02:03 Uhr.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz