A few additional comments....
The (ssget) function is to get a selection set. The "X" in it is the selection mode, which has it look at the entire drawing -- without that, the User will be asked to select objects. In either case, (ssget) will "see" only those things among the selection that fit the criteria in the filter list. With the "X", it finds qualifying things in the entire drawing including Model Space and all Layouts of Paper Space, but in a (command) function calling a command involving object selection [such as ERASE in your example], it will apply the command to only those in the current space. If you want them removed from Model Space and multiple Layouts, that can be done, but not with an ERASE command in a (command) function -- it would need to step through the selection set and use (entdel) on all the Blocks found.
The "INSERT" entity type also finds XREFs [and WMFs, in case you ever use those]. In this case, it wouldn't be likely to ERASE any of those you don't want it to, because presumably none would fit the name filter.
The apostrophe ' before the double left parenthesis is shorthand for the (quote) function, and the left parenthesis immediately after it begins a list [in this case the filter list for selection] -- read about (quote) and its relation to the (list) function in the AutoLisp Reference.
The double double-quote "" near the end is an empty text string, which means Enter, and which completes the object selection in the ERASE command, and therefore finishes the command.
Kent Cooper, AIA