Quick Q on Wk 2 Gaussian Elim Lab

Exercise 1:

I need guidance on the labs and struggling a bit. I was able to solve them on paper but not sure how to solve these issues when using python. Is there any resources that can be recommended?

It’s great that you are first working out the problems on paper. In a case like this, it really helps to first have a clear idea of what the actual steps are before you try to express them in code.

How much python experience or programming experience do you have in other languages? If this is literally your first time doing any kind of programming, then you really should consider taking a python course first. If you already know some other language like C# or JavaScript, then you can probably just read some python tutorials online.

I have experience in python ~ 2 years. I think I might need to draw it out but the code did not seem straightforward.

There aren’t any tricky python language issues in this code. It’s just loops. Maybe the only new thing might be that we’re dealing with numpy arrays here.

You have the clear picture from the pencil and paper method, so my suggestion is just put in lots of print statements and then match what your code is doing to what should be happening.

Got it, ok. Makes me feel better with loops.

When I add print statements to the lab I do not see them only trace messages from the unit tests. Thoughts

Perhaps this means that the code where you placed the print() statement isn’t being executed.

1 Like

I don’t know what you mean by “trace statements”. Please show us the output you are seeing.

Print statements from the unit tests. I did see trace errors but I was able to resolve the issue. thank you for the support.

1 Like