$code$

#include<iostream>
#include<cstdio>
#include<cstdlib>
#include<cstring>
#include<climits>
using namespace std;
typedef long long LL;
int n, m;
char a[][];
bool flg[];
inline char getans(int x, int y) {
char ret = a[x][y];
if (!ret) {
ret = 'A';
while (ret == a[x - ][y] || ret == a[x + ][y] || ret == a[x][y - ] || ret == a[x][y + ]) ++ ret;
}
return ret;
}
inline void cover(int x, int y) {
char c = getans(x, y);
putchar(c);
if (a[x][y]) return;
int sz = ;
while(x + sz <= n && y + sz <= m && getans(x, y + sz) == c) {
sz ++;
}
sz --;
for (int i = x; i <= x + sz; ++ i)
for (int j = y; j <= y + sz; ++ j)
a[i][j] = c;
} int main() {
scanf("%d%d", &n, &m);
for (int i = ; i <= n; ++ i) {
for (int j = ; j <= m; ++ j)
cover(i, j);
putchar('\n');
}
}

最新文章

  1. 前端工程师技能之photoshop巧用系列第二篇——测量篇
  2. .net 应用迁移到Mono 工具 (Moma)
  3. 你可能不再需要Underscore
  4. Mac下安装zshell
  5. mysql innodb 数据打捞(三)innodb 簇不连接页的扫描提取(计划)
  6. [jAudio] JAVA上经典特征提取工具
  7. NPOI导入导出Excel
  8. html css 笔记
  9. Android 调用webservice faultactor 错误
  10. duilib绘制边框
  11. 理解云计算的(IaaS PaaS SaaS)
  12. Python面向对象编程(四)
  13. Mybatis JPA 代码构建
  14. Linux中安装opencv-3.3.1
  15. checkBox半选中状态
  16. vs code使用Git
  17. vtime.hpp
  18. 学习flask需要用到的包
  19. jQuery基础之一
  20. HBuilder+eclipse开发:使用ajax异步传值生成首字母索引

热门文章

  1. js/jquery键盘事件及keycode大全
  2. ubuntu Ifconfig只显示一个lo
  3. Jemeter学习环境部署。
  4. vue-cli 3.x版本执行vue ui命令后提示Error: Cannot find module ‘core-js/modules/es7.object.entries’报错的解决方法
  5. 1. vue.js介绍
  6. 搜索和浏览离线 Wikipedia 维基百科(中/英)数据工具
  7. 设计模式之JDK动态代理源码分析
  8. Bootstrap。
  9. Ansible入门笔记(3)之Playbook
  10. 环境搭建:添加 xgboost 到 Anaconda