Skip to main content
added 35 characters in body
Source Link
Jakube
  • 22k
  • 3
  • 28
  • 108

Pyth, 3234 bytes

.A}Lrw1c2c." WWcÄHþânÌÏB_YWô-WûÄæ­§Òé } 

Try it online: DemonstrationDemonstration

Explanation:

 ."... packed string, gets decoded to: "2 TO TOO TWO T0 B BE BEE B3" c split by spaces c2 split into 2 lists: [['2', 'TO', 'TOO', 'TWO']'TWO', 'T0'], ['B', 'BE', 'BEE', 'B3']] L for each list: w read a line r 1 convert it to uppercase } and test if it is part of this list list .A test if both return true 

Pyth, 32 bytes

.A}Lrw1c2c." WWcÄHþânÌÏB_Y } 

Try it online: Demonstration

Explanation:

 ."... packed string, gets decoded to: "2 TO TOO TWO B BE BEE B3" c split by spaces c2 split into 2 lists: [['2', 'TO', 'TOO', 'TWO'], ['B', 'BE', 'BEE', 'B3']] L for each list: w read a line r 1 convert it to uppercase } and test if it is part of this list list .A test if both return true 

Pyth, 34 bytes

.A}Lrw1c2c." Wô-WûÄæ­§Òé } 

Try it online: Demonstration

Explanation:

 ."... packed string, gets decoded to: "2 TO TOO TWO T0 B BE BEE B3" c split by spaces c2 split into 2 lists: [['2', 'TO', 'TOO', 'TWO', 'T0'], ['B', 'BE', 'BEE', 'B3']] L for each list: w read a line r 1 convert it to uppercase } and test if it is part of this list list .A test if both return true 
Source Link
Jakube
  • 22k
  • 3
  • 28
  • 108

Pyth, 32 bytes

.A}Lrw1c2c." WWcÄHþânÌÏB_Y } 

Try it online: Demonstration

Explanation:

 ."... packed string, gets decoded to: "2 TO TOO TWO B BE BEE B3" c split by spaces c2 split into 2 lists: [['2', 'TO', 'TOO', 'TWO'], ['B', 'BE', 'BEE', 'B3']] L for each list: w read a line r 1 convert it to uppercase } and test if it is part of this list list .A test if both return true