Skip to main content
Commonmark migration
Source Link

##QBIC, 17 bytes

QBIC, 17 bytes

;?A=_fA|#|Af_=A?;

Uses a boring comment-like ttrick to make the code a palindrome. Explanation:

;         Get a string literal from the cmd prompt
?         Print -1 for true and 0 for false in the following comparison
A=        Is A equal to
_fA|      A reversed?

#         Start a 'silent' string literal: This only forces the creation of string B
          with the following text, but doesn't inject a reference to B$ here.
|Af_=A?;  Code, reversed, as a string literal.

##QBIC, 17 bytes

;?A=_fA|#|Af_=A?;

Uses a boring comment-like ttrick to make the code a palindrome. Explanation:

;         Get a string literal from the cmd prompt
?         Print -1 for true and 0 for false in the following comparison
A=        Is A equal to
_fA|      A reversed?

#         Start a 'silent' string literal: This only forces the creation of string B
          with the following text, but doesn't inject a reference to B$ here.
|Af_=A?;  Code, reversed, as a string literal.

QBIC, 17 bytes

;?A=_fA|#|Af_=A?;

Uses a boring comment-like ttrick to make the code a palindrome. Explanation:

;         Get a string literal from the cmd prompt
?         Print -1 for true and 0 for false in the following comparison
A=        Is A equal to
_fA|      A reversed?

#         Start a 'silent' string literal: This only forces the creation of string B
          with the following text, but doesn't inject a reference to B$ here.
|Af_=A?;  Code, reversed, as a string literal.
Source Link
steenbergh
  • 8.1k
  • 1
  • 25
  • 41

##QBIC, 17 bytes

;?A=_fA|#|Af_=A?;

Uses a boring comment-like ttrick to make the code a palindrome. Explanation:

;         Get a string literal from the cmd prompt
?         Print -1 for true and 0 for false in the following comparison
A=        Is A equal to
_fA|      A reversed?

#         Start a 'silent' string literal: This only forces the creation of string B
          with the following text, but doesn't inject a reference to B$ here.
|Af_=A?;  Code, reversed, as a string literal.