代码搜索结果
找到约 10,000 项符合
3 的代码
bo3-3.c
/* bo3-3.c 循环队列(存储结构由c3-3.h定义)的基本操作(9个) */
void InitQueue(SqQueue *Q)
{ /* 构造一个空队列Q */
(*Q).base=(QElemType *)malloc(MAX_QSIZE*sizeof(QElemType));
if(!(*Q).base) /* 存储分配失败 */
exit(O
c3-3.h
/* c3-3.h 队列的顺序存储结构(可用于循环队列和非循环队列) */
#define MAXQSIZE 5 /* 最大队列长度(对于循环队列,最大队列长度要减1) */
typedef struct
{
QElemType *base; /* 初始化的动态分配存储空间 */
int front; /* 头指针,若队列不空,指向队列头元素 */
int r
main3-3.c
/* main3-3.c 循环队列 检验bo3-3.c的主程序 */
#include"c1.h"
typedef int QElemType;
#include"c3-3.h"
#include"bo3-3.c"
void visit(QElemType i)
{
printf("%d ",i);
}
void main()
{
St
bo3-3.c
/* bo3-3.c 循环队列(存储结构由c3-3.h定义)的基本操作(9个) */
Status InitQueue(SqQueue *Q)
{ /* 构造一个空队列Q */
(*Q).base=(QElemType *)malloc(MAXQSIZE*sizeof(QElemType));
if(!(*Q).base) /* 存储分配失败 */
exit(
algo3-3.c
/* algo3-3.c 括号匹配的检验,(限于()、[]) */
typedef char SElemType;
#include"c1.h"
#include"c3-1.h"
#include"bo3-1.c"
void check()
{ /* 对于输入的任意一个字符串,检验括号是否配对 */
SqStack s;
SElemType ch[80
example3_3.m
%编写目标函数
function y=objfun(x)
y=exp(x(1))*(3*x(1)^2+2*x(2)^2+3*x(1)*x(2)+2*x(2)+1);
%编写返回约束值的函数
function [c,ceq]=confun(x)
%非线性不等式约束
c=[1.5+x(1)*x(2)-x(1)-x(2);-x(1)*x(2)-10];
%线性等式约束
ceq=[];
examp3_3.m
syms x y a; f=exp(-1/(y^2+x^2))*sin(x)^2/x^2*(1+1/y^2)^(x+a^2*y^2);
L=limit(limit(f,x,1/sqrt(y)),y,inf)
3-3-4.c
/*中国系统分析员顾问团,http://www.csai.cn*/
/*程序员下午考试指南书籍源码*/
#include
int encode(char *instr, char *outstr){
char *ip, *op ,c ; int k,n;
ip = instr; op = outstr;
while (*ip) {
if (*ip >=
3-3-2.c
/*中国系统分析员顾问团,http://www.csai.cn*/
/*程序员下午考试指南书籍源码*/
#include
int strlen(char *s){
char * t = s;
while (*t++);
return t-s-1;
}
int commstr(char *str1,char *str2, int