Gravitationally lensed quasars are useful for studying astrophysics and cosmology, and enlarging the sample size of lensed quasars is important for multiple studies. In this work, we develop a lens search algorithm for four-image (quad) lensed quasars based on their time variability. In the development of the lens search algorithm, we constructed a pipeline simulating multi-epoch images of lensed quasars in cadenced surveys, accounting for quasar variabilities, quasar hosts, lens galaxies, and the PSF variation. Applying the simulation pipeline to the Hyper Suprime-Cam (HSC) transient survey, we generated HSC-like difference images of the mock lensed quasars from Oguri & Marshalls lens catalog. We further developed a lens search algorithm that picks out variable objects as lensed quasar candidates based on their spatial extent in the difference images. We tested our lens search algorithm with the mock lensed quasars and variable objects from the HSC transient survey. Using difference images from multiple epochs, our lens search algorithm achieves a high true-positive rate (TPR) of 90.1% and a low false-positive rate (FPR) of 2.3% for the bright quads with wide separation. With a preselection of the number of blobs in the difference image, we obtain a TPR of 97.6% and a FPR of 2.6% for the bright quads with wide separation. Even when difference images are only available in one single epoch, our lens search algorithm can still detect the bright quads with wide separation at high TPR of 97.6% and low FPR of 2.4% in the optimal seeing scenario, and at TPR of $sim94%$ and FPR of $sim5%$ in typical scenarios. Therefore, our lens search algorithm is promising and is applicable to ongoing and upcoming cadenced surveys, particularly the HSC transient survey and the Rubin Observatory Legacy Survey of Space and Time, for finding new lensed quasar systems. [abridged]