import std.stdio, std.format, std.algorithm;

struct MyRange {
  int start;
  int end;
  this( int start, int end ) {
	this.start = start;
	this.end = end;
  }

  bool opCmp( MyRange r1 ) {
	return start < r1.start;
  }  
}

void main()
{
  int N, W, H;
  string input = readln;
  formattedRead( input, "%d %d %d\n", &N, &W, &H );
  MyRange[] xs = new MyRange[]( N );
  MyRange[] ys = new MyRange[]( N );
  
  foreach ( i; 0 .. N ) {
	int x, y, w;
	input = readln;
	formattedRead( input, "%d %d %d\n", &x, &y, &w );
	xs[ i ] = MyRange( max( 0, x - w ), min( W, x + w ) );
	ys[ i ] = MyRange( max( 0, y - w ), min( H, y + w ) );
  }

  if ( check( xs, W ) || check( ys, H ) ) {
	writeln( "Yes" );
  } else {
	writeln( "No" );
  }
}

bool check( MyRange[] ary, int ulim ) {
  sort( ary );
  if ( ary[ 0 ].start > 0 ) {
	return false;
  } else {
	int end = 0;
	foreach ( r; ary ) {
	  if ( end < r.start ) {
		return false;
	  } else {
		end = max( end, r.end );
	  }
	}
	return ulim == end;
  }
}