文件名称:jijieshuhuanfang
介绍说明--下载内容均来自于网络,请自行研究使用
给定一个正奇数n,输出n阶幻方。即:将 填入一个 方阵,使方阵的每一行元素的和、每一列元素的和、对角线元素的和均相等。奇数阶幻方可按如下方式排成:将1列于第一行正中,依次将自然数排在其前一个数的右上方(按环绕边界处理);遇到n的倍数时,将下一个自然数排在前一个数的下方。-Given a positive odd number n, the output magic squares of order n. Namely: to fill in a square so that each row of matrix elements and each element and out, and the diagonal elements are equal. Odd-order magic can be arranged as follows: The one in the middle of the first line, followed by the natural number in the top right of the previous number (at the border around the handle) encountered a multiple of n, it will be a natural number row below the previous number.
(系统自动生成,下载前可以参看下载内容)
下载文件列表
奇阶数幻方.cpp
奇阶数幻方.exe
奇阶数幻方.exe