⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 queue.cpp

📁 一个可执行的nbc算法设计与实现 有助大家互相探讨学习
💻 CPP
字号:
#include "stdafx.h"
#include "queue.h"


QNode *queue::GetHead()
{
	return front;
}

void queue::Del_Queue()
{
	QNode *TNd;
	TNd=front;
	front=front->next;
	delete TNd;
	
}

void queue::Insert_Queue(line *L)
{
  QNode *Nd=new QNode;
  Nd->po=L;
  Nd->next=NULL;
  if(front==NULL)
  {
	 front=Nd;
	 rear=Nd;
  }
  else
  {
	  rear->next=Nd;
	  rear=Nd;
  }	
}


int queue::Que_Empty()
{
	if(front==NULL)
		return 1;
	else
		return 0;
}


void queue::Que_Reset()
{
	front=rear=NULL;
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -