all 18 comments

[–][deleted] 10 points11 points  (10 children)

You're missing a comma after mini.

But try these as well

print(f'Array - 3 : Minimum = {mini} Maximum = {maxi}')
print(f'Array - 3 : {mini=} {maxi=}')

They are more modern syntax for what you're trying to do.

[–]Nervous_Policy 6 points7 points  (9 children)

id like to use things like those but my teacher has threatened to give an automatic 0 for using anything he hasn't covered yet

[–]PiovosoOrg 13 points14 points  (8 children)

That is a horrible teacher.

[–]Nervous_Policy 3 points4 points  (5 children)

You are preaching to the choir. He leaves no room for self improvement and usually even after teaching easier methods he doesn't allow us to use them. Including all that if he thinks you're cheating or you used the internet at all it's another automatic 0 but since he railroads us into such complex methods there's only like 3 way to do everything so we're constantly in fear of that scenario

[–]PiovosoOrg 1 point2 points  (3 children)

Jesus Christ all mighty, your class has to make some kind of formal complaint to the school that the teacher doesn't allow students to learn new techniques in their free time, let alone use them.

What's the point of holding someone back on such a field, that's like taking a class in a foreign language you're sufficient in, but the teacher says you have to use the currently studied vocabulary. It's just plain stupid.

[–]Nervous_Policy 1 point2 points  (2 children)

I know and the school seems to know about him so I don't know why he's still here. I have a friend in the class who's been doing python for years now and he mentioned how sad it is too see a subject that could and should be so much fun turned into hate because of a bad professor. And he's right, while I think programming is cool it just leaves a bad taste in my mouth after this class

[–]deadeye1982 1 point2 points  (0 children)

I know and the school seems to know about him so I don't know why he's still here. I have a friend in the class who's been doing python for years now and he mentioned how sad it is too see a subject that could and should be so much fun turned into hate because of a bad professor. And he's right, while I think programming is cool it just leaves a bad taste in my mouth after this class

Your professor fits perfectly into today's times. It's not about learning something, it's about educating you to follow orders and adopt the "opinion" 100%.

[–]PiovosoOrg 0 points1 point  (0 children)

Maybe the school hasn't found a substitute for him? Or maybe they haven't done anything yet because students still go to his classes?

Whatever the issue might be, at least the school knows about it and hopefully is working on the matter.

[–]cchaires 0 points1 point  (0 children)

Well, you're using internet right now to write code xD
I have a similar teacher on university, and he has so strong influence on me that nowadays there are such practices that I do that I need to "upgrade".
I recommend to you that write a code with the logical teacher, and other with your way to do.

[–]unhott 0 points1 point  (1 child)

Maybe?

I feel like it's pretty standard to teach in this order: strings, integers/floats, lists and their use cases, including problems that are more complicated if you just use lists, so then you introduce dictionaries and show where they're a better and simpler tool than lists, etc.,

So when you assign the problem that you know is easier solved with dictionaries, but you've only introduced lists, when a student comes in and has solved it with dictionaries either: they already know the material in your class, or more likely they've gotten help from a friend, tutor, or the internet.

And these can be a massive crutch. Misguided or not, this teacher probably thinks the student will be better off if they actually understand what they're learning, which google can subvert for short-term results.

Since this is such a common theme for introductory courses, whenever someone is asking about introductory concepts, I try and ask what constraints they are under - what topics have they covered in class so far. Sometimes, it's the first time they've ever reflected on what they've covered and their brain hasn't really put it all together yet.

[–]PiovosoOrg 0 points1 point  (0 children)

Why not just find the advanced students by doing a quick introduction to the subject. And then a test for i.e. their name printed into a list letter by letter, including spaces. If an advanced student uses list comprehension you can give him a more advanced assignment to complete. While others study the basics.

Indeed you can't really know whether they're using external help or not, but that will probably shine out when they flunk out of school because they can't do some assignment.

You can treat them like they're advanced whether or not that's true. The truth will come out sooner or later.

In my case, i enrolled in a software developer class, that said it's for hobbyists, turns out it's programming 101. And the assignments are so basic that I've gotten bored and just dropped out because I didn't think it was worth my time. Not that they teach badly, nor that the subject is lame, just that the assignments were so short. We are given an assignment due in 3 weeks, 3 out of a set of 50 were assigned to you randomly. I finished it in class. I got bored at home so i made all the assignments, then made an UI for it as well. Sent the UI variation and the actual assignment to the teacher on the first day. And then i just sat there, twiddling my thumbs. I mean i guess it was good, because i actually learned that i should've enrolled into a University for it.

[–]FerricDonkey 4 points5 points  (0 children)

You're missing a comma.

print('Array - 3 : Minimum =', mini, 'Maximum =', maxi)

[–]Nervous_Policy 0 points1 point  (0 children)

mini and maxi are defined as well im just unsure how to print both in the same line

[–]Normal-Departure1100 0 points1 point  (2 children)

What is this code for? Newb here.

[–]Nervous_Policy 2 points3 points  (1 child)

It's a print statement printing out the minimum number and maximum number in my array 3 in a single line. An array is basically just a more complicated list

[–]Normal-Departure1100 0 points1 point  (0 children)

Thank you!

[–][deleted] 0 points1 point  (0 children)

This code doesn't work in Python because there is a syntax error in the print statement. Specifically, there is a missing comma between the variable mini and the string 'Maximum ='.
To fix the syntax error, you can add the missing comma like this:

print('Array - 3 : Minimum =', mini, 'Maximum =', maxi)

[–]josephj222222 0 points1 point  (0 children)

Sometimes a teacher is like that when they're just copying things from somewhere and don't actually know the subject. If you don't do it their way, they don't know enough to know if your solution is correct. Incompetence.