码农知识堂 - 1000bd
  •   Python
  •   PHP
  •   JS/TS
  •   JAVA
  •   C/C++
  •   C#
  •   GO
  •   Kotlin
  •   Swift
  • C++实现BF、RK、KMP和BM~Qt6完成GUI


      项目


      用C++实现了4个经典的字符串模式匹配算法:BF、RK、KMP和BM,并用Qt6完成了GUI。为了便于直观有效地对4个算法进行测试和对比,设计了3种测试模式:

      1. 单处理;

        使用一个测试数据对单个算法进行测试,查看耗时以及结果是否正确;

      2. 批处理1;

        使用整个数据集对单个算法进行测试,对比不同数据量的耗时;

      3. 批处理2:

        使用一个测试数据对4个算法进行测试,对比不同算法的耗时。



      需要测试文件的朋友可以自己从链接下载。


      PS:合肥工业大学《程序设计与算法训练》(即《数据结构》课程设计)的题目“字符串模式匹配算法比较”可以参考本项目。(毕业老学长奉上,蛤蛤蛤!)

      下面的图片除了第1张为程序结构图,其余均是程序截图或生成的坐标图。


      Machine Translation Contents with a Little Personal Polished:


      Project


      Four classical string pattern matching algorithms: BF, RK, KMP and BM are implemented using C++ and GUI is completed by Qt6. What’s more, In order to test and compare the four algorithms intuitively and effectively, three test modes are designed:


      Single Mode:

      Use single testbench to test one algorithm, and then to check the time-consuming and whether the results are correct;



      Batch Mode 1:

      Use the whole data set to test a single algorithm, and then compare the time-consuming over different amounts of data;


      Batch Mode 2:

      Use single testbench to test the four algorithms, and then compare the time-consuming of each algorithms.


      If you need the testbench used during development, please download them yourself from the link.


      The following pictures except the first one is the program structure diagram than the rest are program screenshots or generated coordinates.
















































































  • 相关阅读:
    python print格式
    合宙Air780e+luatos+腾讯云物联网平台完成设备通信与控制(属性上报+4G远程点灯)
    泛型编程——模板【C++】
    Poco脚本的点击位置与点击偏移
    三十七、【进阶】验证索引的效率
    Springboot 对于数据库字段加密方案(此方案是对字符串处理的方案)
    AtCoder Beginner Contest 254「E bfs」「F st表维护差分数组gcd」
    vue中使用qrcodejs2-fix生成二维码
    Unity --- 曲线与帧事件
    智能机器人代替人工真的有那么强大吗?
  • 原文地址:https://blog.csdn.net/u25th_engineer/article/details/125629095
  • 最新文章
  • 沪漂五周年了:我越来越迷茫了
    Agentic Skill Routing 实战:别再把所有 Skill 塞进 AI Agent 上下文
    MySQL-Seconds_behind_master的精度误差
    [MAF预定义ChatClient中间件-03]CachingChatClient——利用缓存省钱省时间
    AI的至暗历史:从万众期待到被政府撤资,AI的两次死亡徘徊
    Agent OS :五种驯服不确定性的范式
    PortSwigger SQL注入LAB11
    数据库即时编译JIT
    [Begin]AI Learn Data Day 0
    深度学习进阶(二十七)现代 LLM 的核心架构设计其二:SwiGLU
  • 热门文章
  • 十款代码表白小特效 一个比一个浪漫 赶紧收藏起来吧!!!
    奉劝各位学弟学妹们,该打造你的技术影响力了!
    五年了,我在 CSDN 的两个一百万。
    Java俄罗斯方块,老程序员花了一个周末,连接中学年代!
    面试官都震惊,你这网络基础可以啊!
    你真的会用百度吗?我不信 — 那些不为人知的搜索引擎语法
    心情不好的时候,用 Python 画棵樱花树送给自己吧
    通宵一晚做出来的一款类似CS的第一人称射击游戏Demo!原来做游戏也不是很难,连憨憨学妹都学会了!
    13 万字 C 语言从入门到精通保姆级教程2021 年版
    10行代码集2000张美女图,Python爬虫120例,再上征途
小工具 小游戏
Copyright © 2022 侵权请联系2656653265@qq.com    京ICP备2022015340号-1

京公网安备 11010502049817号