#include<iostream.h> void fun(int a) { a=10; //修改參數 } int main() { int a=20; fun(a); //調用fun函數 cout<<a<<endl; //輸出變量,變量的值沒改變 return 0; }