unittest
{
	assert( [ "sippuu" ].parse.expand.solve == "Yes" );
	assert( [ "iphone" ].parse.expand.solve == "No" );
	assert( [ "coffee" ].parse.expand.solve == "Yes" );
}



import std.conv;
import std.range;
import std.stdio;
import std.typecons;

void main()
{
	stdin.byLineCopy.parse.expand.solve.writeln;
}

auto parse( Range )( Range input )
if( isInputRange!Range && is( ElementType!Range == string ) )
{
	auto s = input.front.to!( dchar[] );
	return tuple( s );
}

auto solve( dchar[] s )
{
	return ( s[ 2 ] == s[ 3 ] && s[ 4 ] == s[ 5 ] ) ? "Yes" : "No";
}
