当前位置:网站首页>4276. 擅长C
4276. 擅长C
2022-06-29 01:13:00 【Ray.C.L】

思路:有意思的模拟题
代码:
#include <iostream>
#include <cstring>
#include <algorithm>
using namespace std;
char g[26][7][6];
bool is_first = true;
void write(string word){
if(word.empty()) return ;
char str[7][60] = {
'.'};
if(is_first) is_first = false;
else cout << endl;
for(int i = 0; i < word.size(); i++)
for(int j = 0; j < 7; j++)
for(int k = 0; k < 5; k++)
str[j][i * 6 + k] = g[word[i] - 'A'][j][k];
for(int i = 1; i < word.size(); i++)
for(int j = 0; j < 7; j++)
str[j][i * 6 - 1] = ' ';
for(int i = 0; i < 7; i++)
cout << str[i] << endl;
}
int main()
{
for(int i = 0; i < 26; i++)
for(int j = 0; j < 7; j++)
cin >> g[i][j];
string word;
char c;
while( (c = getchar()) != -1){
if(c >= 'A' && c <= 'Z') word += c;
else{
write(word);
word = "";
}
}
write(word);
return 0;
}
边栏推荐
- mysql数据库修改密码
- 戴口罩人脸数据集和戴口罩人脸生成方法
- Blazor University (34) forms - get form status
- 戴口罩人臉數據集和戴口罩人臉生成方法
- 统计学习方法(4/22)朴素贝叶斯
- 最新Justnews主题源码6.0.1开心版+社交问答插件2.3.1+附教程
- What is the reason for the service crash caused by replacing the easycvr cluster version with the old database?
- Seven mistakes in IT Governance and how to avoid them
- Magic Quadrant of motianlun's 2021 China Database
- DO280分配持久性存储
猜你喜欢

流媒体集群应用与配置:如何在一台服务器部署多个EasyCVR?

GUI Graphical user interface programming example - color selection box

独家分析 | 关于简历和面试

How can multidimensional analysis pre summary work?
![[staff] accent mark, gradually stronger mark and gradually weaker mark](/img/5d/5738bd5503d7ed0621932f901c2e8d.jpg)
[staff] accent mark, gradually stronger mark and gradually weaker mark

有了这款工具,自动化识别验证码再也不是问题

立创eda学习笔记:铺铜死区?孤岛?死铜?

What is the difference between immunohistochemistry and immunohistochemistry?

EasyCVR接入Ehome协议的设备,无法观看设备录像是什么原因?

What kind of life is a tester with a monthly salary of over 10000?
随机推荐
戴口罩人臉數據集和戴口罩人臉生成方法
EasyCVR播放视频出现卡顿花屏时如何解决?
Hello i am back
Streaming media cluster application and configuration: how to deploy multiple easycvr on one server?
Esmm reading notes
Pytorch -- use and modification of existing network model
The latest justnews theme source code 6.0.1 happy version + social Q & a plug-in 2.3.1+ tutorial
linux7(centos7)设置oracle11开机自启动
[MCU club] design of blind water cup based on MCU [simulation design]
QT基于RFID管理系统(可应用于大多数RFID管理系统)
【温度检测】基于matlab GUI热红外图像温度检测系统【含Matlab源码 1920期】
手把手教你搞懂测试环境项目部署
统计字符串中不同回文子序列的个数
【Proteus仿真】4x4矩阵键盘中断方式扫描 +数码管显示
Large-scale case applications to developing post-click conversion rate estimation with MTL
Is l1-031 too fat (10 points)
第八天 脚本与音频
【图像增强】基于matlab人工多重曝光融合AMEF图像去雾【含Matlab源码 1916期】
Interviewer: with the for loop, why do you need foreach??
企业和IT领导者对创新的误解