#include<iostream>
#include<string>
using namespace std;
int main(){
int a,b;
a=b=1;
string sa,sb;
sa=sb="sdf";
cout << a << " " << b << endl;
cout << sa << " " << sb;
return 0;
}
多变量一行赋值
最新推荐文章于 2024-06-01 01:45:00 发布
#include<iostream>
#include<string>
using namespace std;
int main(){
int a,b;
a=b=1;
string sa,sb;
sa=sb="sdf";
cout << a << " " << b << endl;
cout << sa << " " << sb;
return 0;
}