EE308 LAB1_2

taohhoat taohhoat 墨衍会员 · AI 创作全网分发 墨衍智能分发 通过墨衍一键同步至各平台 可同步平台 CSDN微信公众号微博知乎掘金百家号博客园抖音小红书 你的文章也可以这样分发 墨衍会员 ¥399起/年,写一次发全网 我也要 + 加入社区

EE308 LAB1_2 2022

Catalogue

  • EE308 LAB1_2 2022
  • PSP form
  • Basic Idea
  • Design & Implement
  • Code Explanation
  • Result
  • Summary

The Link Your Class https://bbs.csdn.net/forums/MUEE308FZU202201
The Link of Requirement of This Assignment https://bbs.csdn.net/topics/608734907
The Aim of This Assignment Keywords extraction and counting
MU STU ID and FZU STU ID20124066 & 832002123

MY GITHUB:https://github.com/taohhoat/EE308_LAB12

PSP form

Personal Software Process StagesEstimated Time/minutesCompleted Time/minutes
Planning2530
Estimate2530
Development5040
Analysis3030
Design Spec3020
Design Review1010
Coding Standard1510
Design1010
Coding7085
Code Review Planning2020
Test1030
Reporting6570
Test Report1530
Size Measurement1520
Postmortem & Process Improvement4040
total430475

Basic Idea

I use c++ to solve the problem.
I know the most different part in the project is that we need frequently use String and char [] to solve the problem.
First, i review the information about Import a directory usage and how to deal with the content in a ".txt" line by line.
Second, i clearly draw a picture which shows the connection between 4 steps.
I use draw.io to picture a link map.

在这里插入图片描述

Design & Implement

在这里插入图片描述


step 1 and 2:
It is easy to think that we can just use a String array to carry all the keywords, and order to find the words same as the word in the array;
The same way to find the "switch ".

step 3 and 4:
It is hard to discuss because "if else " and "if else if " have same part. So we can use a double loops. First loop is to judge whether " if else if " is finding. If is found, no more operation. Else judge the another "else ".

Code Explanation

在这里插入图片描述


This is where I started using the stack structure. A stack is a data structure in which items are arranged in order, and items can only be inserted and deleted at one end (called the top of the stack). When I find cases, I will sum them up and calculate the number of cases. When I traverse to default, I will end the sum up. Or when I encounter the next switch, I will add the switch and re-stack the number

在这里插入图片描述

when the second one finds the else and then finds the if, if follows, it will print the Boolean to false. I check to see if there is an if or else if form stored at the top of the stack, and count if there is, otherwise it doesn't work

Result

在这里插入图片描述


在这里插入图片描述


在这里插入图片描述


在这里插入图片描述

Performance optimization:
stack using is not a better way than loop, it cause more time because of it's mechanism .Then i may use two loop to replace the process of dealing with the step3 and 4.

Summary

It is the first time i use Git. I know the advantages of Git well which allow me to change and optimize my code better in the next time. And i use github to save my code, it is better to see the change in my process.

...全文

相关推荐

EE-308 LAB4 final version.7z

这是本次实验的压缩包

晨起剪桃花

战国BC472年世界历史地图矢量文件SHP格式.zip

本资源为《战国BC472年世界历史地图矢量文件SHP格式》压缩包,文件大小约 2.26 MB,便于集中下载、整理和使用。具体内容请结合压缩包内的实际文件与说明查看。 在当前可读取的目录中,可见属性表(.dbf)、投影说明文件(.prj)、Shapefile 主文件(.shp)、Shapefile 索引(.shx)。建议解压后保持原有目录结构,先浏览文件清单与说明,再选择需要的资料进行加载或整理。 应用方面,可根据实际资料用于学习练习、资料检索、研究整理或项目参考。使用时可先确定所需内容,建立清晰的文件分类,再按项目要求进行筛选、转换与汇总。 使用 Shapefile 数据时,请把实际配套的 .shp、.shx、.dbf 等文件保存在同一目录,并保持同名关联;加载后再检查坐标系与中文字段显示。如需叠加其它数据,请先统一坐标与字段口径。 数据来源、时间范围、坐标系、字段定义、精度和使用条件,请以实际文件及原始说明为准。本介绍不对文件名之外尚未核实的信息作额外承诺。

白水先森

地方科技局搭建区域性科技成果转化公共服务平台,哪家机构提供的数智化方案更成熟?.docx

科易网基于行业知识库+行业大数据+科技资源要素+AI模型,以AI,赋能技术转移、成果转化、技术经理人培训、知识产权管理、区域产业分析与布局、地方科技招商、创新创业大赛等场景,推出科技创新领域的AI工具、场景化服务和数智化解决方案,推动科技创新与产业创新智能化发展。

BIZKEEN

F500A 立式机触摸屏程序

F500A 立式机触摸屏程序

czhaii

汉语言文学22班 马旭 1243022203 现当代文学读书笔记.pdf

img_to_pdf_1796121273101.pdf

AAA-妙脆角批发
评论
收藏 已收藏
分享
返回顶部