各位大侠们,求解!!

koala1985 2006-02-16 05:20:20
Your boss is re-tiling his bathroom and wishes to know how many unique ways there are to arrange an arbitrary number of tiles on the wall. He has assigned you to figure this out, but won't tell you how many tiles he has.
=====================================================
Input and Output
Design a program that accepts the number of tiles and returns the number of unique different arrangements. An arrangement is unique if it cannot be rotated in two dimensions to match any other arrangement.
For example, if there were 3 tiles, there are 2 possible arrangements:


***

**
*


Note that the following arrangement does not count because it can be rotated on a plane into one of the previous shapes:

*
**

Also note that the following two arrangements are different because they cannot be rotated into the same shape:

***
*

*
***
========================================
Sample Input:
3
Sample Output:
2
...全文
47 回复 打赏 收藏 转发到动态 举报
写回复
用AI写文章
回复
切换为时间正序
请发表友善的回复…
发表回复

62,612

社区成员

发帖
与我相关
我的任务
社区描述
Java 2 Standard Edition
社区管理员
  • Java SE
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧