Generally, it is impossible for the driving school to refund the money easily after paying the money. Because you have signed up for the exam and don't want to take it halfway, it is equivalent to your breach of contract and you need to pay liquidated damages. However, depending on which subject you took, you can negotiate with the driving school, and you should still be able to refund part of it, but it is definitely impossible to get a full refund.
Generally, as long as you don't pass subject 2, you can negotiate with the driving school to refund part of the registration fee, but you won't get much money back after subject 2. How much you can refund depends mainly on your negotiation with the driving school. No one can help you, or you signed a contract with the driving school when you signed up. You can see if there are any terms in the contract.