#!/bin/python from __future__ import division import sys p = 1000000007 n,a,b,q = raw_input().strip().split(' ') n,a,b,q = [int(n),int(a),int(b),int(q)] c = map(int, raw_input().strip().split(' ')) for a0 in xrange(q): queryType,first,second = raw_input().strip().split(' ') queryType,first,second = [int(queryType),int(first),int(second)] if queryType == 1: c[first] = second else: r = second l = first t = c[l:r+1] for i in xrange(r-l+1): if (t[r-l-i]/a)%p != 0: print "No" break elif i == r-l: print "Yes" else: t[r-l-i-1] -= (t[r-l-i]*b/a)