Christ's 'saying' was pretty narrow here:
18 And a certain ruler asked him, saying, Good Teacher, what shall I do to inherit eternal life?
20 Thou knowest the commandments, Do not commit adultery, Do not kill, Do not steal, Do not bear false witness, Honor thy father and mother. Lu 18
If keeping the commandments sends one to heaven then the invert must be true; breaking the commandments sends one to hell.
James 2:8-12,
8 "If ye fulfil the royal law according to the scripture, Thou shalt love thy neighbour as thyself, ye do well:
9 But if ye have respect to persons, ye commit sin, and are convinced of the law as transgressors.
10 For whosoever shall keep the whole law, and
yet offend in one point, he is guilty of all.
11 For he that said, Do not commit adultery, said also, Do not kill. Now if thou commit no adultery, yet if thou kill, thou art become a transgressor of the law.
12 So speak ye, and so do, as they that shall be judged by the law of liberty."
Matthew 5:27-28,
27 "Ye have heard that it was said by them of old time, Thou shalt not commit adultery:
28 But I say unto you, That whosoever looketh on a woman to lust after her hath committed adultery with her already in his heart."
All are guilty of one and therefore as James says that makes you guilty of all.
Jesus told us all are condemned by not believing on Him. We know that 1 John 2:2 says Jesus became the propitiation for sins, He satisfied the Fathers demand for a sacrifice for sin. Belief in Him brings salvation. Rejection of Him brings eternal separation that is the second death.
Jesus said what He did to show no one human being can keep all the Law, the only one what has kept it to the letter is Jesus Himself and thus He was worthy to pay for the sins of all mankind.