问一下这个感叹号代表什么意思?
偶在研究C++链表的结构,弱弱地问一下if(!head)中的感叹号代表什么意思?
node* head_Create()
{ node *head,*n;
in a;
head=NULL;
cout<<"input";
for(cin>>a;a!=-1;cin>>a)
{
n = new node;
n->data=a;
if(!head) head=n;n->next=NULL;----感叹号什么意思
else n->next=head,head=n;
}
return head;
}