[Huawei OD test questions] Guessing crossword puzzles (python) with 100% pass rate, super detailed code comments, code optimization

[Huawei OD machine test real questions 2022&2023] real test catalog @click here @
[Huawei OD machine test real questions] signal transmission and reception & trial reading & @click here @
[Huawei OD machine real test questions] rent a car to ride the greenway & trial reading & @点here@

words puzzle

Time limit: 1s Space limit: 256MB Limited language: unlimited

Title description:

Xiao Wang designed a simple word guessing game. The puzzle of the game is a wrong word, such as new, and the player
needs to guess the correct word in the answer library. The requirements for guessing are as follows:
For a certain riddle and answer word, any of the following conditions is met to indicate a guess:

  1. The sequence is the same after changing, for example, by changing the order of w and e, "nwes" and "news" can be completely corresponded:
  2. After the letter is deduplicated, it is the same ÿ

Guess you like

Origin blog.csdn.net/weixin_45541762/article/details/130673649