代码搜索结果
找到约 15,351 项符合
9 的代码
9.44.c
<mark>9</mark>.44④ 已知某哈希表的装载因子小于1,哈希函数
H(key)为关键字(标识符)的第一个字母在字母表中
的序号,处理冲突的方法为线性探测开放定址法。
试编写一个按第一个字母的顺序输出哈希表中所有
关键字的算法。
实现下列函数:
void PrintKeys(HashTable ht, void(*print)(StrKeyType));
/* 依题意用print输出关键字 */ ...
9.32.c
9.32③ 编写递归算法,求二叉排序树上的小于x且
最靠近x的值a和大于x且最靠近x的值b。如果这样的
a或b值不存在,则分别返回MINV和MAXV。
实现下列函数:
void OutX(BiTree t, KeyType x, KeyType &a, KeyType &b);
/* a: Return the nearest and smaller value to x, */
9.lnp
"9.obj"
TO "9"
9-4.c
/*9-4.c*/
#include
#include
#define N1 64
#define N2 32
#define N4 16
#define N8 8
#define N16 4
#define END 0
enum NOTES
{
C10=131,D10=147,E10=165,F10=175,G10=196,A10=220,B1
9-7.c
/*9-7.c*/
#define SPEED 10
#include
#include
void pause(int time)
{
int t1,t2;
union REGS in;
union REGS out;
in.h.ah=0x2c;
int86(0x21, &in, &out);
t1=t2=100*out.h.dh+out.
9-2.c
/*9-2.c*/
#include
main() /* music */
{
int note,length;
length=10;
do {
note=getchar( );
play(note,length);
}while (note!='q');
}
play(int note, int l)
{
int tone;
9-1.c
/* 9-1.c可生成噪声的主程序 */
#define FALSE 0
#define TRUE 1
#include
main()
{
int snd; /* which sound to produce */
int cnt; /* number of times to repeat sound */
int note; /* Cur
9-6.c
/*9-6.c*/
#include
#include
#include
#include
void main(int argc,char *argv[])
{
FILE *fp;
int rate;
char sound_high[3];
float sound_long;
register int i=
9-5.c
/*9-5.c*/
#include
#include
#include
#include
#include
#define N1 64
#define N2 32
#define N4 16
#define N8 8
#define N16 4
#define END 0
void
9-3.c
/*9-3.c*/
#include
#include
#include
#include
main()
{
int i,j;
randomize();
while(!bioskey(1))
{
i=rand()*5000;
sound(i);
delay(10);
}
nosound();
}