哪位大神与七位伙伴帮忙看看,有错误啊

各位大神,帮忙看看哪里错了,我是照着左边提醒那里打的。谢谢!
各位大神,帮忙看看哪里错了,我是照着左边提醒那里打的。谢谢!还有求解这里是什么意思?
if(countMap1[i]){
countMap1[i]++;
countMap1[i]=1;
if(countMap2[i]){
countMap2[i]++;
countMap2[i]=1;我不理解这里的if括号里面的是什么意思,还请各位大神解惑。十分感谢!!代码如下:&!DOCTYPE HTML&&html&&head&
&meta http-equiv="Content-Type" content="text/ charset=gb18030"&
&title&Untitled Document&/title&
&/head&&body&
&script type="text/javascript"&
* param1 Array
* param2 Array
* return true or false
function arraysSimilar(arr1, arr2){
if(!(arr1 instanceof Array)
|| !(arr2 instanceof Array)){
if(arr1.length!==arr2.length){
var i = 0,
n = arr1.length,
countMap1 = {},
countMap2 = {},
TYPES = ['string', 'boolean', 'number', 'undefined', 'null', 'function', 'date', 'window'];
for(; i & i++){
t1 = typeOf(arr1[i]);
t2 = typeOf(arr2[i]);
if(countMap1[i]){
countMap1[i]++;
countMap1[i]=1;
if(countMap2[i]){
countMap2[i]++;
countMap2[i]=1;
function typeOf(ele){
if(ele === null){
r = 'null';
}else if(ele instanceof Array){
r = 'array';
}else if(ele === window){
r = 'window';
}else if(ele instanceof Date){
r = 'date'
for(i = 0 , n = TYPES. i & i++){
if(countMap1[TYPES[i]]
!== countMap2[TYPES[i]]){
&script src="testData.js"&&/script&&/body&&/html&
感觉代码有缺失,t1 t2都没有和countMap1 countMap2关联
写下你的评论...
Copyright (C)
All Rights Reserved | 京ICP备 号-2小木虫 --- 500万硕博科研人员喜爱的学术科研平台
&&查看话题
哪位大神会用comsol软件,帮忙看一下哪里出错了!!!
大神帮忙指教一下,小弟不胜感激!
QQ截图35.png
大神知不知道怎么解决?我是刚接触,按他教程来做的,做了两次都出现上面的错误,不知道哪一步出的错。
我也遇到这问题,刚接触,求解:hand:
你在study里面找找有没有paramatic sweeping,如果你设置了参数化扫描,就删除就好了,我现在没安装那个软件,没办法截图给你看。还有另一处可以定义参数化扫描的,你把study下的选项逐个来看看就可以看到了,虽然这比较麻烦。。。
虽然,问题还没有解决,但是还是的谢谢您!
大神在请教您个问题,出现这种错误,是什么原因啊?亟待解决谢谢!!!
QQ截图12.png
研究生必备与500万研究生在线互动!
扫描下载送金币哪位大神帮我看看这篇英语作文有没有错误?Hi,my name is Helen Smith and I'm fourteen years old.I'm a student in the Class1 Grade7.My favourite colour is green and my favourite subject is English.I like swimming,sometimes I go swimming on Sunday,so my favourite day is Sunday.I have a nice family——My father,my mother,my brother and me.My father is an actor and my mother is a science teacher.My brother is a policeman,he work at a police station.And you?
my brother and me--my brother and Ihe work at --he works at
为您推荐:
其他类似问题
扫描下载二维码哪位大神帮忙看看啊,这个错误是怎么回事_百度知道
哪位大神帮忙看看啊,这个错误是怎么回事
我有更好的答案
要有兼容性好的(兼容ide、Raid模式的安装)并能自。但关键是、achi什么错误..。用u盘或者硬盘这些都是可以的、顺利解决 系统无法启动 的问题了,这样就可以全程自动?直接换个验证过的系统盘重装系统就行了?系统无法启动了,且安装速度非常快
其他类似问题
为您推荐:
等待您来回答
下载知道APP
随时随地咨询
出门在外也不愁共有 1825 人关注过本帖
标题:各位大神帮忙看看这个程序,error C2143: 语法错误 : 缺少“{”(在“&”的前 ...
等 级:新手上路
&&已结贴√
&&问题点数:20&&回复次数:5&&&
各位大神帮忙看看这个程序,error C2143: 语法错误 : 缺少“{”(在“&”的前面)error C2059: 语法错误:“&”
#include&stdio.h&
#include&malloc.h&
#include&stdlib.h&
#define TRUE 1
#define FALSE 0
#define OK 1
#define ERROR 0
#define INFEASIBLE -1
#define OVERFLOW -2
typedef int S//Status是函数的类型,其值是函数的结果状态代码
//链表的函数
#define LIST_INIT_SIZE 100//线性表存储空间的初始分配量
#define LISTINCREMENT 10//线性表储存空间的分配增量
typedef int ElemT
typedef struct
&&& ElemType *//储存空间的地址
&&&//当前长度
&&&//当前分配的储存容量(以sizeof(ElemType)为单位
//------构造一个空的线性表-P23
Status Initlist_Sq(SqList &L)
&&& L.elem=(ElemType * )malloc(LIST_INIT_SIZE*sizeof(ElemType));
&&& if(!L.elem)exit(OVERFLOW);//内存分配失败
&&& L.length=0;//空表长度为0
&&& L.//初始储存容量
&&& return OK;
}//InitList_sq
//-----线性表的双向链表储存结构-P35
typedef struct dulnode
&&& struct shuang *
&&& struct shuang *
}dulnode,*
//-----线性表的单链表存储结构-P28
typedef struct sinnode
&&& struct sinnode *
}sinnode,*
//------一个带头结点的线性链表-P37
typedef struct headnode
&&& struct headnode *
}headnode,*headLinkL
typedef struct
&&& headLinkList head,//分别指向线性列表中的头结点和最后一个结点
&&&//指示线性列表中数据元素的个数
//----顺序栈
#define STACK_INIT_SIZE 100 //存储空间初始分配量
#define STACKINCREMENT 10&&//存储空间分配增量
typedef int SElemT
typedef struct
&&& SElemType * //在栈构造之前和销毁之后,base的值为NULL
&&& SElemType *&&//栈顶指针
&&& //当前已分配的存储空间,以元素为单位
int InitStack(SqStack &S)&&//构建一个空栈
&&& S.base=(SElemType *)malloc(STACK_INIT_SIZE*sizeof(SElemType));
&&& if(!S.base)exit(OVERFLOW);
&&& S.top=S.
&&& S.stacksize=STACK_INIT_SIZE;
&&& return OK;
Status Push(SqStack &S,SElemType e)//插入元素e为新的栈顶元素
&&& if(S.top-S.base&=S.stacksize)//栈满,追加存储空间
&&&&&&&&S.base=(SElemType *)realloc(S.base,(S.stacksize+STACKINCREMENT)*sizeof(SElemType));
&&&&&&&&if(!S.base)exit(OVERFLOW);//存储分配失败
&&&&&&&&S.top=S.base+S.
&&&&&&&&S.stacksize+=STACKINCREMENT;
&&& *S.top++=e;
&&& return OK;
int Pop(SqStack &S,SElemType &e)//若栈不空,则删除S的栈顶元素,用e返回其值,并返回OK;否则返回ERROR
&&& if(S.top==S.base)return ERROR;
&&& e=*--S.
&&& return OK;
#include&zhan.h&
int zuoye(int length,int n)
&&& int i,l,N;
&&& char E;
&&& char e[]={'a','b','c','d','e','f','h'};
&&& InitStack(q);
&&& while(!length)
&&&&&&&&N=n;
&&&&&&&&for(i=0;N--&0&&length--&0;)
&&&&&&&&&&&&i++;
&&&&&&&&&&&&Push(q,e[i]);
&&&&&&&&N=n;
&&&&&&&&for(i=0;N--&0&&length--&0;)
&&&&&&&&&&&{
&&&&&&&&&&&&&&i=l-
&&&&&&&&&&&&&&Pop(q,&e[i]);
&&&&&&&&&&&&&&printf(&%c&,e[i]);
&&&&&&&&&&&}
&&&&&&&&printf(&/0&);
&&& return OK;
void main()
&&& int length,n;
&&& length=4;
&&& zuoye(length,n);
搜索更多相关主题的帖子:
来 自:江西财经大学
等 级:友情版主
威 望:72
帖 子:3103
专家分:11930
&&得分:10&
‘&’是C++的东西,把文件名改成 .cpp就可以了
[fly]存在即是合理[/fly]
等 级:青峰侠
帖 子:388
专家分:1722
&&得分:10&
&#include&stdio.h&
&#include&malloc.h&
&#include&stdlib.h&
&#define TRUE 1
&#define FALSE 0
&#define OK 1
&#define ERROR 0
&#define INFEASIBLE -1
&#define OVERFLOW -2
typedef int S//Status是函数的类型,其值是函数的结果状态代码
//链表的函数
#define LIST_INIT_SIZE 100//线性表存储空间的初始分配量
&#define LISTINCREMENT 10//线性表储存空间的分配增量
&typedef int ElemT
typedef struct
&&&&&ElemType *//储存空间的地址
&&&&&//当前长度
&&&&&//当前分配的储存容量(以sizeof(ElemType)为单位
//------构造一个空的线性表-P23
&Status Initlist_Sq(SqList &L)
&&&&&L.elem=(ElemType * )malloc(LIST_INIT_SIZE*sizeof(ElemType));
&&&&&if(!L.elem)exit(OVERFLOW);//内存分配失败
&&&&&L.length=0;//空表长度为0
&&&&&L.//初始储存容量
&&&&&return OK;
&}//InitList_sq
//-----线性表的双向链表储存结构-P35
&typedef struct dulnode
&&&&&ElemT
&&&&&struct shuang *
&&&&&struct shuang *
&}dulnode,*
//-----线性表的单链表存储结构-P28
&typedef struct sinnode
&&&&&ElemT
&&&&&struct sinnode *
&}sinnode,*
//------一个带头结点的线性链表-P37
&typedef struct headnode
&&&&&ElemT
&&&&&struct headnode *
&}headnode,*headLinkL
&typedef struct
&&&&&headLinkList head,//分别指向线性列表中的头结点和最后一个结点
&&&&&//指示线性列表中数据元素的个数
//----顺序栈
#define STACK_INIT_SIZE 100 //存储空间初始分配量
&#define STACKINCREMENT 10&&//存储空间分配增量
typedef char SElemT
typedef struct
&&&&&SElemType * //在栈构造之前和销毁之后,base的值为NULL
&&&&&SElemType *&&//栈顶指针
&&&&& //当前已分配的存储空间,以元素为单位
int InitStack(SqStack &S)&&//构建一个空栈
&&&&&S.base=(SElemType *)malloc(STACK_INIT_SIZE*sizeof(SElemType));
&&&&&if(!S.base)exit(OVERFLOW);
&&&&&S.top=S.
&&&&&S.stacksize=STACK_INIT_SIZE;
&&&&&return OK;
Status Push(SqStack &S,SElemType e)//插入元素e为新的栈顶元素
&&&&&if(S.top-S.base&=S.stacksize)//栈满,追加存储空间
&&&&&&&&&S.base=(SElemType *)realloc(S.base,(S.stacksize+STACKINCREMENT)*sizeof(SElemType));
&&&&&&&&&if(!S.base)exit(OVERFLOW);//存储分配失败
&&&&&&&&&S.top=S.base+S.
&&&&&&&&&S.stacksize+=STACKINCREMENT;
&&&&&*S.top++=e;
&&&&&return OK;
int Pop(SqStack &S,SElemType &e)//若栈不空,则删除S的栈顶元素,用e返回其值,并返回OK;否则返回ERROR
&&&&&if(S.top==S.base)return ERROR;
&&&&&e=*--S.
&&&&&return OK;
int zuoye(int length,int n)
&&&&&int i,l,N;
&&&&&char E;
&&&&&char e[]={'a','b','c','d','e','f','h'};
&&&&&InitStack(q);
&&&&&while(!length)
&&&&&&&&&N=n;
&&&&&&&&&for(i=0;N--&0&&length--&0;)
&&&&&&&&&{
&&&&&&&&&&&& i++;
&&&&&&&&&&&& Push(q,e[i]);
&&&&&&&&&}
&&&&&&&&N=n;
&&&&&&&&&for(i=0;N--&0&&length--&0;)
&&&&&&&&&&&&{
&&&&&&&&&&&&&&&i=l-
&&&&&&&&&&&&&&&Pop(q,e[i]);
&&&&&&&&&&&&&&&printf(&%c&,e[i]);
&&&&&&&&&&&&}
&&&&&&&&&printf(&/0&);
&&&&&return OK;
int main(void)
&&&&&int length,n;
&&&&&length=4;
&&&&&zuoye(length,n);
&&&&&system(&pause&); return 0;
//错误是没了的,,,
等 级:新手上路
回复 2楼 azzbcc
谢谢大神,太无敌了。
因为我是初学者,用的是清华版的C语言数据结构。
我以前也是不改的直接使用.CPP,后来才改成.C了。
请问为什么C就不能用 & 呢?
我是按照书上定义的。
等 级:新手上路
回复 3楼 小xiong
楼上的方法对了。也谢谢你帮忙,
来 自:江西财经大学
等 级:友情版主
威 望:72
帖 子:3103
专家分:11930
以下是引用scuddym在 20:53:52的发言:
谢谢大神,太无敌了。
因为我是初学者,用的是清华版的C语言数据结构。
我以前也是不改的直接使用.CPP,后来才改成.C了。
请问为什么C就不能用 & 呢?
我是按照书上定义的。
因为C语言 没有引用
[fly]存在即是合理[/fly]
版权所有,并保留所有权利。
Powered by , Processed in 0.030697 second(s), 8 queries.
Copyright&, BCCN.NET, All Rights Reserved}

我要回帖

更多关于 跳大神 的文章

更多推荐

版权声明:文章内容来源于网络,版权归原作者所有,如有侵权请点击这里与我们联系,我们将及时删除。

点击添加站长微信