Make a mind map. Write down words and ideas connected to the topic in any order. Once you start writing, you will think of more ideas. Don’t worry if your ideas are not organised – just write, write, write.
Close your eyes and picture the situation in your head for a few seconds. This will help you think of ideas. This technique can be useful when you write stories. Describe the picture you see in your imagination.
Write down your opinions. In more formal writing, remember to include other people’s opinions to give a balanced argument.
To practise these ideas, have a look at this opinion essay and this for and against essay. These are the type of writing tasks where it's very important that you have clear ideas before you start writing.
Do you usually have ideas of what to write in exams? Do you spend time thinking about your ideas before you start writing?