先来看下面这三段代码: //Example1: public class Example1 { static void check(int a) { a++; } public static void main(String[]args) { int x=10; check(x); System.out.println(“Example1.x=”+x);} } //Example2: public class Example2 { static void check(StringBuffer o…
######################非固定参数################## #第一种方式:def send_alert(msg,*users):##*users 是非固定参数,将传过来的参数打包成元祖, for u in users: print("报警发送给:",u)send_alert("报警短信内容","guo","hao","lei")# 想写几个人就写几个人,第一个是msg,消息内…