Skip to main content
1 of 4
Luis Mendo
  • 105.3k
  • 9
  • 135
  • 372

MATL, 12 bytes

q&=sqt&=tsvv

The input is a string enclosed in single quotes. Single quotes in the string are escaped by duplicating.

The output is a matrix, which is truthy if it is non-empty and doesn't contains zeros, and is falsy otherwise.

Try it online! Or verify all test cases, including the standard truthiness/falsiness test for convenience.

Luis Mendo
  • 105.3k
  • 9
  • 135
  • 372