-
counting-sheep
前一段时间我有睡眠问题。我曾经躺在床上,盯着天花板,几个小时。后来有一天,我的外婆建议我试着数羊后,我已经上床睡觉。与往常一样,当我的奶奶暗示的东西,我决定尝试一下。唯一的问题是,有没有羊的时候,我就去睡觉各地进行计数。
创意,因为我,这是不会阻止我。我坐下来写,使得字符,其中#代表羊的网格,而计算机程序。草(或任何你喜欢的,只是没有羊)。为了使计算更有趣,我也决定要数绵羊,而不是单一的成群的牛羊。两只羊在同一个群,如果他们都有一个共同的一面(上,下,左或右)。另外,如果羊A是在同一羊群如羊B和羊B处于同一羊群如羊℃,然后羊A和C是在同一个群。
现在,我已经有了一个新的问题。虽然这些计数羊居然帮我睡着了,我觉得这是非常无聊的。为了解决这个问题,我决定我需要做的计数为我另一台计算机上的程序。然后,我就可以只启动这两个程序之前,我去睡觉,我会睡个好觉,直到没有任何干扰的早晨。我需要你给我写的这个程序。(A while ago I had trouble sleeping. I used to lie awake, staring at the ceiling, for hours and hours. Then one day my grandmother suggested I tried counting sheep after I d gone to bed. As always when my grandmother suggests things, I decided to try it out. The only problem was, there were no sheep around to be counted when I went to bed.
Creative as I am, that wasn t going to stop me. I sat down and wrote a computer program that made a grid of characters, where# represents a sheep, while . is grass (or whatever you like, just not sheep). To make the counting a little more interesting, I also decided I wanted to count flocks of sheep instead of single sheep. Two sheep are in the same flock if they share a common side (up, down, right or left). Also, if sheep A is in the same flock as sheep B, and sheep B is in the same flock as sheep C, then sheeps A and C are in the same flock.
Now, I ve got a new problem. Though counting these sheep actually helps me fall asleep, I find)
- 2014-11-20 16:33:12下载
- 积分:1
-
c++异常处理
c++异常处理,针对C++的,在coodbolck中测试通过的,C++开发中很少想java中开发中那样,有着完善的异常处理机制和自动来及回收
- 2023-01-21 00:10:04下载
- 积分:1
-
guzhanglubo
这是一篇有关故障录波仪如何开发的硕士论文,论文行文清楚、逻辑分明,重点讲述了故障录波器的算法,值得看。(This is a fault recorder on how to develop the master's thesis papers lines clearly and logically distinct, and highlight the fault recorder algorithm worth observing.)
- 2006-09-06 14:25:50下载
- 积分:1
-
pingpufenxi
声音的频谱分析
读取文件,分析频谱,画图(Read the file of the sound spectrum analysis, analysis of the spectrum, drawing)
- 2012-09-03 20:56:06下载
- 积分:1
-
glew-1.10.0-win32
opengl的扩展库glew,包含源码与连接库,2013年更新,版本至1.10(opengl extensions library glew, including source code and link library, 2013 updated to version 1.10)
- 2020-10-15 20:07:29下载
- 积分:1
-
ThreadSync
Win CE平台实现线程同步演示,使用交叉编译方式!(Win CE platform demo thread synchronization, use the cross compiler way!)
- 2007-12-12 20:39:20下载
- 积分:1
-
MDIEditer
多文档编辑器,实现基本的文本编辑,通过rtf文件保存文件文本信息(Multi document editor, to achieve the basic text editor)
- 2015-06-09 20:44:40下载
- 积分:1
-
两轮平衡车源码 stm 32
两轮平衡小车源码,stm32 ,自己根据自己的情况修凯一些就可以玩了
- 2022-08-10 06:18:12下载
- 积分:1
-
LedBuzzer
点阵LED、数码管、独立LED和无源蜂鸣器的驱动模块(Dot matrix LED, digital control, independence and passive buzzer LED driver module)
- 2016-01-17 21:37:00下载
- 积分:1
-
InspectorExpressEagleEye
研华的视觉软件,可以在电脑上运行四个摄像头,设置各种工具运用(To study the visual software, China can run on the computer four cameras, set the various tool use)
- 2015-09-24 15:45:11下载
- 积分:1