CodeBus
www.codebus.net
Search
Sign in
Sign up
Hot Search :
Source
embeded
web
remote control
p2p
game
More...
Location :
Home
Search - INT 1
Main Category
SourceCode
Documents
Books
WEB Code
Develop Tools
Other resource
Search - INT 1 - List
[
Other Games
]
BitCheck
DL : 0
做过任务系统吗?里面用到的检测任务状态的变量,也许你用INT 或 SHORT 或BOOL 可我用的是BYTE 看谁的效率高!-Mission Systems has done it? Detection task used inside a state variable, perhaps you SHORT or INT or BOOL I used to see who is the efficiency of high-BYTE!
Date
: 2026-01-07
Size
: 1.17mb
User
:
李金峰
[
Other Games
]
juzhenxiangcheng
DL : 0
编写程序,可以实现m*n矩阵和n*p矩阵相乘。m,n,p均小于10,矩阵元素为整数。 分析: 首先我们可以根据题意写出函数头。可以定为void MatrixMutiply(int m,int n,int p,long lMatrix1[MAX][MAX],long lMatrix2[MAX][MAX],long lMatrixResult[MAX][MAX]),其中lMatrix1和lMatrix2分别是输入的m*n矩阵和n*p矩阵,lMatrixResult是输出的m*p矩阵。 因为m,n和p都是未知量,要进行处理的矩阵大小是变量。但我们可以定义比较大的二维数组,只使用其中的部分数组元素。 矩阵相乘的算法比较简单,输入一个m*n矩阵和一个n*p矩阵,结果必然是m*p矩阵,有m*p个元素,每个元素都需要计算,可以使用m*p嵌套循环进行计算。 根据矩阵乘法公式: 可以用循环直接套用上面的公式计算每个元素。嵌套循环内部进行累加前,一定要注意对累加变量进行清零。-Write a program, you can achieve the m* n matrix and n* p matrix multiplied. m, n, p are less than 10, the matrix elements are integers. Analysis: First of all, we can write the function header according to the meaning of the questions. As void MatrixMutiply (int m, int n, int p, long lMatrix1 [MAX] [MAX], long lMatrix2 [MAX] [MAX], long lMatrixResult [MAX] [MAX]) of which lMatrix1 and lMatrix2, are input m* N matrix and n* p matrix, lMatrixResult is the output of m* p matrix. M, n and p are unknown quantity, the size of the matrix to be processed is variable. However, we can define a large two-dimensional arrays, which use only part of the array elements. M* p nested relatively simple matrix multiplication algorithm, the input of an m* n matrix, and an n* p matrix, the inevitable result is a matrix of m* p, there are m* p elements, each element needs to be calculated and can be used loop calculation. Matrix multiplication formula: cycle directly apply the above formula to calculate ea
Date
: 2026-01-07
Size
: 11kb
User
:
郑雯雯
[
Other Games
]
namefight
DL : 0
以前自己编的一个小游戏,输入姓名然后可以对战,可以自娱自乐一下-#include <stdlib.h> #include <time.h> #include <windows.h> #define S Sleep(1000) #define P printf char name1[20],name2[20] int k1,k2,i,t1,t2,sxq int x1=100,x2=100,pow1,pow2,spe1,spe2 void main() { void xz(int pow1,int pow2,int spe1,int spe2) void zs(int c) int xh,error char js START: while(1) { P(" \n · 名字对战游戏v2.2 · \n\n") P(" ====================\n | 1.开始游戏 |\n") P(" \n | 2.游戏介绍 |\n") P(" \n | 3.关 于 |\n") P(" \n | 4.退 出 |\n
Date
: 2026-01-07
Size
: 2kb
User
:
安若
[
Other Games
]
Sanke
DL : 0
C++写的贪吃蛇程序。里面有几个int变量是可以删掉的。只有两百多行的代码,很多功能没有实现。但是基本功能算是有了吧。-C++ write the Snake program. There are several int variables can be deleted. Over two hundred lines of code, a lot of features. But the basic functions regarded to have it.
Date
: 2026-01-07
Size
: 562kb
User
:
林海
[
Other Games
]
Snake1
DL : 0
void Pos(int x,int y) { COORD pos; HANDLE hOutput; pos.X=x; pos.Y=y; hOutput=GetStdHandle(STD_OUTPUT_HANDLE); SetConsoleCursorPosition(hOutput,pos); }
Date
: 2026-01-07
Size
: 1kb
User
:
chenjianqing
CodeBus
is one of the largest source code repositories on the Internet!
Contact us :
1999-2046
CodeBus
All Rights Reserved.