Whir of Invention

Oracle Text

Improvise (Your artifacts can help cast this spell. Each artifact you tap after you're done activating mana abilities pays for 1.)

Search your library for an artifact card with converted mana cost X or less, put it onto the battlefield, then shuffle your library.