[英] hi

查看:65
本文介绍了嗨的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,我是高中生,我需要大家的帮助。所以

我必须用C ++编写一个程序,我必须在国际象棋桌上放置9个皇后

而不与另一个相匹配。我已经安排了8个女王但是

九个是不可能的,可以帮我一些......

Hello everyone I am high school student and I need everyone''s help. So
I have to do a program in C++, I must place 9 queens in chess table
without matching one with another. I already placed eight queens but
nine is imposible, can somebone please help me...

推荐答案

* de******@yahoo.com
大家好我是谁高中生,我需要每个人的帮助。所以我必须用C ++做一个程序,我必须把9个皇后放在国际象棋桌上
而不是相互匹配。我已经放了八个皇后但是九个是不可能的,可以帮助我一些人...
Hello everyone I am high school student and I need everyone''s help. So
I have to do a program in C++, I must place 9 queens in chess table
without matching one with another. I already placed eight queens but
nine is imposible, can somebone please help me...




在普通的国际象棋规则下9个皇后是不可能的,因为在至少一个

行必须包含至少2个皇后。


然而,这是[comp.lang.c ++]中的OFF-TOPIC。 />

后续因此设置为[comp.programming],请发布到

适当的论坛。


- -

答:因为它弄乱了人们通常阅读文字的顺序。

问:为什么这么糟糕?

A:热门发布。

问:usenet和电子邮件中最烦人的事情是什么?



9 queens is impossible under ordinary rules of chess, since at least one
row must then contain at least 2 queens.

This is, however, OFF-TOPIC in [comp.lang.c++].

Follow-ups therefore set to [comp.programming], and please post to
appropriate forums.

--
A: Because it messes up the order in which people normally read text.
Q: Why is it such a bad thing?
A: Top-posting.
Q: What is the most annoying thing on usenet and in e-mail?


de ****** @ yahoo.com 写道:
大家好,我是高中生,我需要每个人的帮助。所以我必须用C ++做一个程序,我必须把9个皇后放在国际象棋桌上
而不是相互匹配。我已经安排了8个女王,但是9个是不可能的,有些人可以帮助我...
Hello everyone I am high school student and I need everyone''s help. So
I have to do a program in C++, I must place 9 queens in chess table
without matching one with another. I already placed eight queens but
nine is imposible, can somebone please help me...




九是不可能的,即使在C ++中也是如此。


想一想,国际象棋棋盘是8x8,所以九个皇后至少有两个女王必须在同一排。因此他们互相攻击,因此
因此不可能有9个女王。


john



Nine is impossible, even in C++.

Think aout it, a chess board is 8x8, so with nine queens at least two
queen must be on the same row. Therefore they attack each other,
therefore nine queens is impossible.

john


文章< CW ****************** @ newsfe4-win.ntli.net>,

John Harrison< jo ****** *******@hotmail.com>写道:
In article <CW******************@newsfe4-win.ntli.net>,
John Harrison <jo*************@hotmail.com> wrote:
de******@yahoo.com 写道:
大家好,我是高中生,我需要大家的帮助。所以我必须用C ++做一个程序,我必须把9个皇后放在国际象棋桌上
而不是相互匹配。我已经放了八个皇后但是九个是不可能的,有些人可以帮助我...
Hello everyone I am high school student and I need everyone''s help. So
I have to do a program in C++, I must place 9 queens in chess table
without matching one with another. I already placed eight queens but
nine is imposible, can somebone please help me...



九是不可能的,即使在C ++中也是如此。

想想看,国际象棋棋盘是8x8,所以有九个皇后,至少两个女王必须在同一排。因此他们互相攻击,因此九个皇后是不可能的。

约翰



Nine is impossible, even in C++.

Think aout it, a chess board is 8x8, so with nine queens at least two
queen must be on the same row. Therefore they attack each other,
therefore nine queens is impossible.

john




实际上,更好的答案是你没有给我们足够的信息。 A / $
更有趣的问题是将N个皇后放在NxN板上,没有两个

皇后互相攻击。例如,证明N = 2时不可能获得这个

是微不足道的。也许他正在谈论解决这个问题,更多的是b $ b复杂,N = 9的问题?



Actually, a better answer is "You haven''t given us enough information". A
more interesting problem is placing N queens on an NxN board with no two
queens attacking each other. It''s trivial to prove, for example, that this
is impossible for N=2. Maybe he was talking about solving this, more
complex, problem for N=9?


这篇关于嗨的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆