31. Refactor - Tidying up with functions

Questions and discussion for this lecture live here. Fire away by hitting Reply below :fire:

Hi Sean,
Hope you’re doing well.
I’ve come this far in the course. I’m not even an intermediate Python user, I only know basic concepts. I followed these last classes by reproducing all the steps of your classes and eventually, I was able to understand all. However, I had some questions about what should my focus be in the next classes.
What should I do? Trying to write the code myself? Or, follow what you do in this course and the next courses try to do it myself?

Hi Edson,

Good to hear from you.

The best way to go from beginner programmer to someone who feels competent and proficient is to simply write code. Typically you start by following closely what someone else (me in this case) is doing and slowly but surely you build up a level of familiarity with the code structure and syntax. Quite soon you will feel confident enough to either modify the codes I have written or write your own to solve your own specific problems.

As a next step, I would suggest continuing with the next course - for you this would be Beam & Frame Analysis using the Direct Stiffness Method in Python.

This will have the benefit of further developing your understanding of the direct stiffness method and also giving you more time to write code.

I hope that makes sense. To give a little context, I learned to code years ago by tackling trivially easy problems and slowly building up to more and more complex ones. You really can go very far once you’ve understood the basic building blocks, loops, functions, control flow etc.

Good luck and enjoy the process!

Seán

Hi Seán,
I solved the “Truss Example 2” with what I have learned in previous lessons. It was even simpler than I thought. I couldn’t get the plot right anyway, I still consider that I addressed the challenge’s resolution.
Now I’m going to watch the way that you’ll solve it.
Your explanations are excellent, it’s easy to handle the challenge.
All the Best.

I was able to build the displacement graph after watching your class.
Everything is fine now!

1 Like