This function turns the chain into a string that can be sent to the group
Added send_code, get_chain_from_user functions. The get_chain_from_user generates a chain from a given user and returns an array in reverse sequential order.