????? ?????????????, ???????????? ????? CyberForum.ru
???? ????????

??????? ?????????, ???????? ?????????? ?????????? X ? Y - C++

?????
???????????
???????????? ??????
?????? ???? ???????
C++ ???? ? ????? ??????? http://www.cyberforum.ru/cpp-beginners/thread95639.html
????? ??????. ????????? ?????? ??????? ?????? ?? ????????? ????? ? ???????? ??? ?? ?????. ??? ???? ???? ? ????? ????? ???????? ? ???? ????????? ???????. ?????? ?? ? ?????????: ???? ? ????? ??? ???...
C++ c++ ? ??? ?????? ????? ? ?????? ??????. ??????? ? ?????? c++, ?? ????? ??????? ? php ? wap, ?? ??? ??? ???? ??????, ? ?? ????? ??? ????? ??? ???????? ? ?? ??? pocket gcc ? ?????? ????? ???? ?? ???????????????... http://www.cyberforum.ru/cpp-beginners/thread95628.html
????? ??????? C++
????????, ??????????, ? ????? ? ???? ?????????. 1 ?????????? ?????????? ????????????? ????? ???????????? ??????? f(x)=11x2+23x+1,1 ???????? ??????? ? ??????? ???????? (????? ???????), ? ????????? ...
C++ ???????????? ?????????? ?????? ?? ????????? ???????
???? ????????? ??????, 5*6 ???????????? ?????????? ??????, ?????? ??????? ???????? ????? ??????????? ?? ?????? ???????? ???????????????? ???????.
C++ ?? ???? ???????????? ????? ? ????????? http://www.cyberforum.ru/cpp-beginners/thread95597.html
???? ???????? ? ?????????. ???????: ??? ???????? ??????? ????????? ???????? ????????? ???????: - ???????????? ??????????? ??????? ????????, ??????????? ???????? ????? ??????? ???????? ??????????...
C++ ????????! ??? ??? ????????? #include "stdafx.h" #include <iostream> #include <stdio.h> #include <conio.h> #include <limits> using namespace std; int _tmain(int argc, _TCHAR* argv) { int L(0),C(0),... ?????????

???????? ????????? ????????
kazak
3038 / 2359 / 157
???????????: 11.03.2009
?????????: 5,405
??????????? ?????: 1
15.02.2010, 10:24
?????? ????????? ?? taras atavin ?????????? ?????????
C++
1
2
3
4
5
6
template <TBase> void Swap(TBase X,Y)
{
 X&=Y;
 Y&=X;
 X&=Y;
}
??? ?????? ?? ??????. ??-?????? ?????????? ???? ?????????? ?? ??????:
C++
1
template <TBase> void Swap(TBase &x,&y)
??-?????? ??? ????? ????????? ???????????? ??????????? ???:
C++
1
2
3
4
5
{
   x ^= y;
   y ^= x;
   x ^= y;
}
?????? ??? x &= y => x & y
y &= x => y & ( x & y) = > x & y
x &= y => (x & y) & (x & y) => x & y

x ^= y => x ^ y
y ^= x => y ^ (x ^ y) => x ^ (y ^ y) => x ^ 0 => x
x ^= y => (x ^ y) ^ x => y ^ (x ^ x) => y ^ 0 => y

????????? ????? 4 ??????
?????? ????????? ?? kazak ?????????? ?????????
??? ?????? ?? ??????. ??-?????? ?????????? ???? ?????????? ?? ??????:
? ? ?? ?????????? ???? ????????? ?? ??????????, ??? ? ????? ? ????
1
 
?????????? - ????? ?????????????, ???????????? ?????, ????????????????
Powered by vBulletin® Version 3.8.9
Copyright ©2000 - 2017, vBulletin Solutions, Inc.
???????@Mail.ru