Preview:
contract ExampleContract{
	function encodingXY(uint x, uint256 y) public pure returns (bytes memory) {
		return abi.encode(x,y);
	}
	
	function getATuple(bytes memory encoding) public pure returns (uint256, uint256) {
		(uint256 x, uint256 y) = abi.decode(encoding, (uint256, uint256));
		return(x,y);
	}
}
downloadDownload PNG downloadDownload JPEG downloadDownload SVG

Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!

Click to optimize width for Twitter