Interesting

What to do if I dont understand a code?

What to do if I dont understand a code?

You need to sit down and read, take away the things that might distract you and focus, also use a strategy like do ide and conquer, splitting the code into sections and analyze them individually, when you understand each section, try to understand how they interact, also if the code includes the tests, use them!

Can I copy others code?

It is never ok to copy and paste code from an open source project directly into your proprietary code. Don’t do it. Not only does copying and pasting code put your company (and perhaps your job) at risk, but it’s not leveraging the benefits that come with using open source code.

How do you read code?

As a beginner, how we read code is also a lesson to invest time and effort into. Reading code is not easy. It is not enough to simply read source code. You are trying to understand the design and thoughts of others. An editor you can use effectively. You will need the ability to quickly search for keywords or variables.

READ ALSO:   How can I make my philodendron grow faster?

What is the best way to learn source code?

Source code is like a LEGO kid, only already assembled. If you want to understand how it’s put together, you need to interact with it, even sometimes pick it apart. With code, it’s helpful to read older versions of the same source. Read the diffs from Git, and try to figure out how a specific feature is implemented (Changelogs are useful for this).

Why is it so hard to understand someone else’s code?

When faced with “someone else’s code” we don’t have that. We are faced with pages and pages of code. And often written in a style that is dissimilar to our own. This can lead us to think that the style of the code is the problem. That if only the style was “correct” (read: like my own) then it would be “easier” to understand.

Do programmers need to read code?

As programmers, we deal with source code every day. After years of study, most programmers can “write” code, or at least copy and modify it. Still, the way we teach programming emphasizes the art of writing code, not how to read it. When I say “read code” I refer to the practice of reading source code on purpose.