ANSWER - Writing magic will vary depending on both the castor and the type of magic. Sometimes spells can be an instinctive and spontaneous working that need little or no planning. There are witches who never write their spells down and even witches who never plan ahead and cast purely on instinct.
There are other witches who craft spell wording very precisely – some even insist on it rhyming - I can’t see much value in the rhyming myself but it can be a good focus for the mind and perhaps makes the writer think more carefully about the words that they are using.
Other spells are built up over time with wording added over different stages.
In answer to your question yes it is perfectly possible to craft a spell within a very short timescale. Witches cannot always afford the luxury of time and traditionally we have always had to rely on our ability to ‘cast on the hop’.