In a certain code language, the word 'REASON' is encoded as TDDQSK. Using the same rule, how is the word PRAYER coded?
Step-by-step Solution:
\[ \textbf{Given:}\quad \text{REASON} \longrightarrow \text{TDDQSK} \] \[ \text{Find the rule by letter shifts (A=1,Z=26):} \] \[ \begin{array}{c|cccccc} \text{Position } & 1 & 2 & 3 & 4 & 5 & 6\\\hline \text{Plain} & R & E & A & S & O & N\\ \text{Cipher} & T & D & D & Q & S & K\\\hline \text{Shift} & +2 & -1 & +3 & -2 & +4 & -3 \end{array} \] \[ \text{So the pattern of shifts is: } +2,\ -1,\ +3,\ -2,\ +4,\ -3,\ \dots \] \[ \text{Apply the same shifts to } \text{PRAYER:} \] \[ \begin{array}{c|cccccc} \text{Position } & 1 & 2 & 3 & 4 & 5 & 6\\\hline \text{Plain} & P & R & A & Y & E & R\\ \text{Shift} & +2 & -1 & +3 & -2 & +4 & -3\\\hline \text{Resulting letter} & R & Q & D & W & I & O \end{array} \] \[ \boxed{\text{PRAYER} \longrightarrow \textbf{RQDWIO}} \]