<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def gray2bin(G):
 """Convert a gray-coded vector into a binary-coded vector."""

    return farray([G[i:].uxor() for i, _ in enumerate(G)])