目录 💮前言 🍀模块的相关概念 🌹 1. 什么是模块 🌹 2. 使用模块的好处 🍀模块的使用 🌹 1. 自定义模块 💮一、re模块下的基本使用方法 🍀1、findall方法 🍀2、search方法 🍀3、match方法 🍀4、spilt方法 🍀5、sub方法 🍀6、subn方法 🍀7、compile方法 🍀8、finditer方法 🍀9、注意事项 🌹1、findall的优先级查询 🌹2、 split的优先级查询 💮结语 💮前言 💮一、re模块下的基本使用方法 要使用re模块前必须要熟悉掌握正则表达式的使用规则,如果不会的话可以看如下博客 🍀1、findall方法 🍀2、search方法 🍀3、match方法 🍀4、spilt方法 🍀 5、sub方法 🍀6、subn方法 🍀7、compile方法 🍀8、finditer方法 🍀9、注意事项 🌹1、findall的优先级查询 🌹2、 split的优先级查询 💮结语