function Main( input ){

	var strs = 'KIHBR', withoutA = input.split( 'A' ).join( '' );
	if( strs === withoutA ) console.log( 'YES' );
	else console.log( 'NO' );

}

Main( require( 'fs' ).readFileSync( '/dev/stdin', 'utf8' ) );