Learning is an individual process. How much time you need to reach a particular level depends on various factors including personal engagement, time invested in the learning process and how one makes use of additional practice materials.
In most cases, it will be quicker for you to learn German. If you have already learnt one or more languages, it matters a lot whether you attend a language course in your home country or in Germany-where you can interact with the language outside of the classroom setting.
The intensity of the lessons also plays a critical role in the learning process (i.e. if one takes part an intensive course, evening lessons etc.). Please contact the examination center of your choice for personal advice.