Generation

generate functionTue, 09 May 2023

Pasar de un entero a bytes

def int_to_bytes(x): return x.to_bytes((x.bit_length() + 7) // 8, 'big') int_to_bytes(x)

Questions about programming?Chat with your personal AI assistant