Skip to main content
added 94 characters in body
Source Link
Olivier Grégoire
  • 14.4k
  • 3
  • 32
  • 56

Java (OpenJDK 8), 60 bytes

(p,u,g,U,G,t)->U<1|p.charAt(t+(u==U?0:G.contains(g)?3:6))>90

Try it online!

The mapping for the type is the following: 1 means r, 2 means w and 3 means x.

Java (OpenJDK 8), 60 bytes

(p,u,g,U,G,t)->U<1|p.charAt(t+(u==U?0:G.contains(g)?3:6))>90

Try it online!

Java (OpenJDK 8), 60 bytes

(p,u,g,U,G,t)->U<1|p.charAt(t+(u==U?0:G.contains(g)?3:6))>90

Try it online!

The mapping for the type is the following: 1 means r, 2 means w and 3 means x.

deleted 93 characters in body
Source Link
Olivier Grégoire
  • 14.4k
  • 3
  • 32
  • 56

Java (OpenJDK 8), 9860 bytes

(p,u,g,U,G,t)->U<1|p.replaceAll("s|t","x").substringcharAt(u=t+(u==U?10:G.contains(g)?43:76),u+3).contains(t)>90

Try it online!

(Still golfing atm)Try it online!

Java (OpenJDK 8), 98 bytes

(p,u,g,U,G,t)->U<1|p.replaceAll("s|t","x").substring(u=(u==U?1:G.contains(g)?4:7),u+3).contains(t)

Try it online!

(Still golfing atm)

Java (OpenJDK 8), 60 bytes

(p,u,g,U,G,t)->U<1|p.charAt(t+(u==U?0:G.contains(g)?3:6))>90

Try it online!

Source Link
Olivier Grégoire
  • 14.4k
  • 3
  • 32
  • 56

Java (OpenJDK 8), 98 bytes

(p,u,g,U,G,t)->U<1|p.replaceAll("s|t","x").substring(u=(u==U?1:G.contains(g)?4:7),u+3).contains(t)

Try it online!

(Still golfing atm)