代码搜索:SWAP
找到约 10,000 项符合「SWAP」的源代码
代码结果 10,000
www.eeworm.com/read/168218/9932166
h swap.h
#ifndef Swap_
#define Swap_
template
inline void Swap(T& a, T& b)
{// Swap a and b.
T temp = a; a = b; b = temp;
}
#endif
www.eeworm.com/read/168218/9932693
cpp swap.cpp
// exchange values of two elements
#include
#include "swap.h"
void main(void)
{
int a = 2, b = 3;
Swap(a,b);
cout
www.eeworm.com/read/168218/9933325
h swap.h
#ifndef Swap_
#define Swap_
template
inline void Swap(T& a, T& b)
{// Swap a and b.
T temp = a; a = b; b = temp;
}
#endif
www.eeworm.com/read/168218/9933386
cpp swap.cpp
// exchange values of two elements
#include
#include "swap.h"
void main(void)
{
int a = 2, b = 3;
Swap(a,b);
cout
www.eeworm.com/read/165650/10055338
opt swap.opt
www.eeworm.com/read/165650/10055339
dsw swap.dsw
Microsoft Developer Studio Workspace File, Format Version 6.00
# 警告: 不能编辑或删除该工作区文件!
###############################################################################
Project: "swap"=".\swap.dsp"
www.eeworm.com/read/165650/10055341
ncb swap.ncb
www.eeworm.com/read/165650/10055343
plg swap.plg
Build Log
--------------------Configuration: swap - Win32 Debug--------------------
Command Lines
Creating temporary file "C:\DOCUME~1\User\LOC
www.eeworm.com/read/165650/10055345
cpp swap.cpp
#include
#include
int s(int &x,int &y)
{
x=x+y;
y=x-y;
x=x-y;
return 1;
}
void main()
{
int a,b;
a=4;
b=6;
printf("Before Swap:a=%d,b=%d