Dual Quantization for random walks with application to credit derivatives