SB
Nobody could have been justified by the mosaic law so everyone was a sinner before God.
Every human being that is to be saved and justified it's only through the belief in Jesus sacrifice.
I hope these bible verses gives you the answer.
"because by the works of the Law none of mankind will be justified in His sight; for through the Law comes knowledge of sin. But now apart from the Law the righteousness of God has been revealed, being witnessed by the Law and the Prophets, but it is the righteousness of God through faith in Jesus Christ for all those who believe; for there is no distinction, being justified as a gift by His grace through the redemption which is in Christ Jesus, whom God displayed publicly as a propitiation in His blood through faith. This was to demonstrate His righteousness, because in God’s merciful restraint He let the sins previously committed go unpunished; for the demonstration, that is, of His righteousness at the present time, so that He would be just and the justifier of the one who has faith in Jesus. Where then is boasting? It has been excluded. By what kind of law? Of works? No, but by a law of faith. For we maintain that a person is justified by faith apart from works of the Law. Or is God the God of Jews only? Is He not the God of Gentiles also? Yes, of Gentiles also, since indeed God who will justify the circumcised by faith and the uncircumcised through faith is one. Do we then nullify the Law through faith? Far from it! On the contrary, we establish the Law."
Romans 3:20-22, 24-31
"nevertheless, knowing that a person is not justified by works of the Law but through faith in Christ Jesus, even we have believed in Christ Jesus, so that we may be justified by faith in Christ and not by works of the Law; since by works of the Law no flesh will be justified. But if, while seeking to be justified in Christ, we ourselves have also been found sinners, is Christ then a servant of sin? Far from it! For if I rebuild what I have once destroyed, I prove myself to be a wrongdoer. For through the Law I died to the Law, so that I might live for God. I have been crucified with Christ; and it is no longer I who live, but Christ lives in me; and the life which I now live in the flesh I live by faith in the Son of God, who loved me and gave Himself up for me. I do not nullify the grace of God, for if righteousness comes through the Law, then Christ died needlessly.”
Galatians
However, after someone is saved they need to walk in the good works god prepared for them.
"For by grace you have been saved through faith; and this is not of yourselves, it is the gift of God; not a result of works, so that no one may boast. For we are His workmanship, created in Christ Jesus for good works, which God prepared beforehand so that we would walk in them."
Ephesians 2:8-10
"Now the deeds of the flesh are evident, which are: sexual immorality, impurity, indecent behavior, idolatry, witchcraft, hostilities, strife, jealousy, outbursts of anger, selfish ambition, dissensions, factions, envy, drunkenness, carousing, and things like these, of which I forewarn you, just as I have forewarned you, that those who practice such things will not inherit the kingdom of God. But the fruit of the Spirit is love, joy, peace, patience, kindness, goodness, faithfulness, gentleness, self-control; against such things there is no law. Now those who belong to Christ Jesus crucified the flesh with its passions and desires. If we live by the Spirit, let’s follow the Spirit as well."
Galatians 5:19-25
"You will know them by their fruits. Grapes are not gathered from thorn bushes, nor figs from thistles, are they? So every good tree bears good fruit, but the bad tree bears bad fruit."
Matthew 7:16-17