Show what you have tried. Think of it as proof that you aren't lazy.
I solve problems line this using pencil and paper first, then I write down the logic I used to perform the task. Once I have that written down, converting to computer code is usually easy.