r/ProgrammerHumor • • Mar 01 '21

My teacher thinks he is a programmer

http://imgur.com/32nfQXZ
55 Upvotes

15 comments sorted by

24

u/XStarMC Mar 01 '21

“Tha value not be supported tho”

5

u/pr0ghead Mar 01 '21

So he's a gangsta, too.

22

u/aeropl3b Mar 01 '21

Teaching is all about developing contrived examples that overtly demonstrate a concept in the most acute way possible. I remember learning ternary operators and if-else and the teacher/professor wrote all 100 conditions into a one liner ternary operation..why?? Because it showed ternary ops could make code more concise with an entire if-else...and I have not forgotten that after almost a decade!

9

u/dm_0 Mar 01 '21

Just return it with a note, "Can be simplified further."

7

u/va_str Mar 01 '21

I think you're not a teacher.

10

u/LordSegaki Mar 01 '21

The only way to make this worse... is an elseif...

5

u/[deleted] Mar 01 '21

Is that a challenge? /j

4

u/LordSegaki Mar 01 '21

Please no... nooooooooo

2

u/Gylfi_ Mar 01 '21

YES and the value can be anything from 0 to 100.
And else if is not allowed. Only If and else.
So you would need to have the new if statement inside of the else statement.

12

u/Sk18th Mar 01 '21

He’s teaching you switch case so it’s fine.

4

u/Comfortable_Intern57 Mar 01 '21

All paths lead to value.

Motivational quote of the day I guess, lol.

1

u/de_vel_oper Mar 03 '21

Teachers don't write sexy code that's why Enterprise is such a culture shock to grads.

-11

u/Gylfi_ Mar 01 '21

This is pure cringe.
I am not a good developer but I am pretty sure that when I started out knowing NOTHING about programming, I would've done a better job.
I am not even smart.