#!/usr/bin/perl -w

use strict;
use v5.30;

my $in = '00101000101111010';
my $len = 272;

while (length($in) < $len) {
	my $l1 = join('', reverse split(//, $in));
	$l1 =~ y/01/10/;
	$in .= '0' . $l1;
}

$in = substr($in, 0, $len);
while (length($in) % 2 == 0) {
	my $l1 = '';
	while ($in =~ /../g) {
		$l1 .= ($& eq '11' || $& eq '00') ? '1' : '0';
	}
	$in = $l1;
}

say $in;

	
