you can "learn", but it is the same and when you start to learn coding, or do homework, you read the solution and "aaah, I get it", but next time you still won't be able to do it unless you've done without reading the answer before.
reading code is not the same as writing code, the second one is much harder.
reading code is not the same as writing code, the second one is much harder.