Skip to content

Kac291/My-phython-learning-quizzes

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

My Python Learning Quizzes

这个仓库记录了我学习 Python 过程中的练习题。

已完成题目

  1. Paren Chunks: 将括号字符串拆分为独立的闭合块。 in fact i can use battle == 0 to identify if the () has been closed, but i think this one is my first inspiratin, so i just finished based on this, and actually it doesnt have difference in efficiency except the lines of code can be less.
  2. Inverse Permutation: 检查列表是否为排列并生成逆映射字典。 learning outcomes:I have mastered the use of Python set() for membership testing, achieving a constant time complexity of $O(1)$, which is significantly more efficient than lists. I’ve gained a deep understanding of how sets utilize hashing to locate elements in a single step and learned the underlying mechanics of collision resolution—specifically how Python's algorithm finds the next available slot when hash values (remainders) collide.

About

for recording my learning process

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors