There are currently nine feature length films in the core Fast & Furious/The Fast and the Furious media franchise, a series of films about bald men scowling and driving cars very fast. The names of the films, as can be seen, follow a completely logical and sensible convention:
- The Fast and the Furious
- 2 Fast 2 Furious
- The Fast and the Furious: Tokyo Drift
- Fast & Furious
- Fast Five
- Fast & Furious 6
- Furious 7
- The Fate of the Furious
- F9
I'm a Hollywood producer working on the new, tenth Fast & Furious film, and I'm struggling to find a title which hasn't yet been used. Please write me a piece of code - as short as possible - which takes in my input string, and returns a truthy value if any of the following are true:
- the input string is already an existing Fast & Furious film title
- the input string differs from an existing Fast & Furious film title only by replacing an existing number with
tenor10 - the input string differs from an existing Fast & Furious film title only by replacing
&withand(or vice versa).
For instance, all of these strings would return a truthy value:
- The Fast and the Furious (matches check 1)
- The Fast & the Furious (matches check 3)
- Fast and Furious 10 (matches checks 2 and 3)
- 10 Fast 2 Furious (matches check 2)
- Furious Ten (matches check 2)
- F10 and FTEN (match check 2)
And all of these strings would return a falsy value:
- The Fast or The Furious
- Fast Times at Ridgemont High
- Fast/Furious 10
- Too Fast Too Furious
- Ten Furious
- Fast Ten Furious
- The Fast and the Furious: Kyoto Cruise
Fate of the Furious, as a pun, is obviously a tricky case. Unless you're very driven, you don't need to support puns, just exact text matches. If you can create a new Fast & Furious film title which is a pun, please share.
Clarifications
- The matching is not case-sensitive, so the input string can be in lowercase. The film company design team will work out how to depict your title on the posters anyway, and the answer is 'in red, with speedy lines'.
- I've clarified that the numbering match should only be true if an existing number in the title has been replaced with the string
10orten.
Fast and Furious 10 (matches checks 2 and 3)appears inconsistent with the rules. This is derived fromFast & Furious 6by changing a number AND by substituting& -> andbut checks 2 and 3 (as written) say ONLY one change (not both.) \$\endgroup\$