initial mccsearch code