It depends, of course, on what you are taught. But almost all major courses teach 'classical Latin' as a default standard, and that standard is a slightly idealised version of Latin that represents literary writing in the middle of the 1st century BC, covering the end of the Republic and the start of the empire. It crystallises around authors such as Cicero, Caesar, Vergil, etc..
The further you go from this core temporally and in terms of literature, the more variation you can find, but this is the 'version' of classical Latin generally taught today.
Latin education today is generally split into two camps. One, led by classicists, favors "Classical Latin" and the other, led by the Catholic Church, favors "Ecclesiastical Latin" (also commonly known as "Church Latin"). Other variants are taught, but Latin learners are almost always taught Classical or Church Latin first. Church Latin used to dominate Latin education, but since the Catholic Church has deemphasized Latin usage, Classical Latin is becoming more popular relatively.
As for when these were used, Classical Latin starts in the Late Republic. The writings of Varro and (especially) Cicero are often considered to be early seminal works of Latin Literature and they formed an important part of Roman Latin curriculum (the writings of Virgil would gain a similar status a half century later, but his works were poetic). For reference Cicero lived from 106BC to 43BC and the vast majority of his works date from 70BC to his death. It's worth pointing out that Classical Latin was primarily a prestige dialect of the educated and upper class. Meanwhile the spoken language of Roman commoners was "Vulgar Latin". Since Classical Latin was a prestige dialect, it is difficult to determine when exactly stopped being used in speech, but literature through the 2nd century AD is generally considered part of Classical Latin. After this point written Latin becomes somewhat inconsistent and seems to be a mixture of Classical and Vulgar Latin with the influence from each varying by author.
Church Latin was never used in Roman times, but it is not substantially different than Classical Latin due to persistent Classical influences on written Latin. Church Latin's pronunciation was heavily influenced by Medieval Italian whereas Classical Latin as taught today is Linguists and Classicists reconstruction of how Romans pronounced it. Church Latin was also influenced by Vulgar Latin and thus has simpler syntax and the lexicon is a little different.