12分求救
查看原帖
12分求救
1396410
yuzehao3楼主2024/12/15 20:17
#include<bits/stdc++.h>
using namespace std;
string a,b,c,d,e;
int t;
string str;
int main(){
	cin>>str;
	for(int i=0;i<str.size();i++){
		t=str[i];
		switch(t){
			case '0':
				a+="..... ";b+=".***. ";c+=".***. ";d+=".***. ";e+="..... ";break;
			case '1':
				a+="****. ";b+="****. ";c+="****. ";d+="****. ";e+="****. ";break;
			case '2':
				a+="..... ";b+="****. ";c+="..... ";d+=".**** ";e+="..... ";break;
			case '3': 
				a+="..... ";b+="****. ";c+="..... ";d+="****. ";e+="..... ";break;
		}
	}
	cout<<a<<endl<<b<<endl<<c<<endl<<d<<endl<<e;
	return 0;
}
2024/12/15 20:17
加载中...