Defendant was charged in the indictment with aiming and firing a rifle at one Alexander Carrier on the evening of June 30, 1958. There was evidence that a bullet had passed through the right rear tire of a truck which Carrier was driving. The People contended that the bullet was fired by defendant from a second-floor window of his home, after the truck, driven by Carrier, had passed about 15 feet beyond the window. As part of the People’s proof that the crime charged had been committed, evidence was introduced that Carrier proceeded about a block and a half, and then stopped to change his right-rear tire which was flat. Evidence on behalf of defendant that Carrier had driven a much greater distance before he stopped, was excluded. In our opinion, such exclusion was error. The excluded evidence tended to contradict material evidence received during the People’s case to establish that the shot was fired from a window in defendant’s home. It was also error, in our opinion, to exclude evidence by the witness Cavoti as to defendant’s good reputation. The objections by the prosecutor might properly have been considered as affecting the weight of the evidence, but were not sufficient to require its exclusion. It is also our opinion that the cross-examination of Carrier was unduly restricted by the exclusion of evidence that he had testified in the Magistrates’ Court that on the evening of the alleged assault he was unable to identify, as the voice of this defendant, the voice of a person who, apparently from defendant’s window, had shouted: "I’ll blow all your brains out.” On the trial Carrier had testified that the person who had shouted these words was the defendant and that he (Carrier) identified his voice, having talked to him on the following day at the police station. Inquiry as to whether he had not testified in the Magistrates’ Court that he could not identify the voice was excluded on the ground that no foundation had been laid. In our opinion, although the witness Carrier was not asked whether, at the hearing in the Magistrates’ Court, he had been asked specific questions and had given specific answers, the question as framed was sufficient to give the witness warning that the testimony he had given at a specified time and place and on a prior occasion would be used to impeach his testimony on trial. Undoubtedly the most accurate mode of laying the foundation for later impeaching testimony is to ask the witness whether at a stated time and place he made a contradictory statement, and to quote to the witness the exact words of the alleged prior statement. The rule is flexible, however, and its object is merely to prevent the witness from being taken by surprise, and to afford him an opportunity to deny making the statement or to explain its inconsistency. It is not necessary that the question used as the foundation should be in the exact words of the prior statement (Patchin v. Astor Mut. Ins. Co., 13 N. Y. 268, 273; People v. Schuyler, 106 N. Y. 298; Squier v. Hanover Fire Ins. Co., 162 N. Y. 552; Larkin v. Nassau Elec. R. R. Co., 205 N. Y. 267, 269). The question propounded in the instant case stated the substance and effect of the testimony previously given by the witness, and, in the proper exercise of discretion, it should have been permitted in view of its importance to the defendant. Nolan, P. J., Beldock, ICleinfeld, Christ and Pette, JJ., concur.