当前位置: 首页 > wzjs >正文

一个公司如何做多个网站备案自动app优化下载

一个公司如何做多个网站备案,自动app优化下载,用vs2015做网站,wordpress微商城模板下载地址栈-Stack 1. 介绍2. 栈的实现2.1 基于链表的实现2.2 基于数组的实现 3. 栈操作CreateInitilizateDestoryPushPopTopEmptySize 1. 介绍 栈(stack) 是一种遵循先入后出逻辑的线性数据结构。顶部称为“栈顶”,底部称为“栈底”。把元素添加到栈…

栈-Stack

  • 1. 介绍
  • 2. 栈的实现
    • 2.1 基于链表的实现
    • 2.2 基于数组的实现
  • 3. 栈操作
    • Create
    • Initilizate
    • Destory
    • Push
    • Pop
    • Top
    • Empty
    • Size

1. 介绍

栈(stack) 是一种遵循先入后出逻辑的线性数据结构。顶部称为“栈顶”,底部称为“栈底”。把元素添加到栈顶的操作叫作“入栈”,删除栈顶元素的操作叫作“出栈”。
请添加图片描述

2. 栈的实现

2.1 基于链表的实现

请添加图片描述请添加图片描述请添加图片描述

2.2 基于数组的实现

请添加图片描述请添加图片描述
请添加图片描述

3. 栈操作

Create

typedef int STDataType;
typedef struct Stack
{STDataType* a;int top;int capacity;
}ST;

Initilizate

void STInit(ST* pst) {assert(pst);pst->a = NULL;//pst->top = -1;// top Points to the top of the stackpst->top = 0;// top Points to the next data on the top of the stackpst->capacity = 0;
}

Destory

void STDestory(ST* pst) {assert(pst);free(pst->a);pst->top = pst->capacity = 0;
}

Push

void STPush(ST* pst, STDataType x) {// Enpend capacityif (pst->top == pst->capacity) {int newCapacity = pst->capacity == 0 ? 4 : pst->capacity * 2;// If memblock is NULL, realloc behaves the same way as malloc and allocates a new block of size bytes. STDataType* tmp = (STDataType*)realloc(pst->a, newCapacity * sizeof(STDataType));if (tmp == NULL) {perror("relloc fail");return;}pst->a = tmp;pst->capacity = newCapacity;}pst->a[pst->top] = x;pst->top++;
}

Pop

void STPop(ST* pst) {assert(pst);assert(!STEmpty(pst));pst->top--;
}

Top

STDataType STTop(ST* pst) {assert(pst);assert(!STEmpty(pst));// top Points to the next data on the top of the stackreturn pst->a[pst->top - 1];
}

Empty

bool STEmpty(ST* pst) {assert(pst);return pst->top == 0;
}

Size

int STSize(ST* pst) {assert(pst);return pst->top;
}
http://www.dtcms.com/wzjs/320376.html

相关文章:

  • 同一个网站绑定多个域名宁波网络推广团队
  • .net网站方案指数基金是什么意思
  • 苏州做网站哪家专业百度推广渠道代理
  • 空间域名续费 网站维护发票如何开免费网站安全软件下载
  • 甘肃省建设工程网上投标网站沈阳百度快照优化公司
  • 东莞核酸检测时间seo文章优化方法
  • 外贸网站个人简介学校招生网络营销方案
  • 甘肃做网站的公司关键时刻
  • 我在征婚网站认识一个做IT刚刚突发1惊天大事
  • 本地电脑做网站谷歌推广代理
  • 做网站是要云空间吗网络推广外包公司
  • 产品做网站如何谁来维护价格做一个企业网站大概需要多少钱
  • wordpress 列表页面sem优化策略
  • 自己做电影网站违法吗三只松鼠网络营销方案策划书
  • 网站 手机版 电脑版 怎么做十大营销策划公司排名
  • 怎么用PS做网站广告图北京网站seo招聘
  • 免费制作网站平台淘宝关键词优化
  • 家政保洁公司网站建设方案营销策略有哪些内容
  • 福建建设工程有限公司网站在线视频观看免费视频22
  • 网站建设柚子网络科技在哪里chrome官网下载
  • 网站制作是不是要一个后台百度网站统计
  • 佛山专业网站建设报价世界羽联巡回赛总决赛
  • 电商网站开发详细介绍百度指数明星人气榜
  • 租用服务器建设网站费用宣传推广方案模板
  • 郑州网站建设 .cc西安seo工作室
  • 网站建设青岛上海百度推广优化排名
  • 做网站销售大概多少钱潍坊新闻头条最新消息
  • 深圳做网站行业网站优化有哪些技巧
  • 怎么用阿里云建设网站重庆网络seo
  • 深圳网站建设便宜信科网络查看网站流量的工具