Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
Just bring one senior developer from microsoft and tell him to teach your dumb teacher
-
PRein11877yMaybe he comes from a background of C and doesn't want to change habits.
It is ever so slightly more beneficial to do it his way if you declare a few variables and give them the same value. .. unless of course the compilers haven't improved in the past few years. -
Had a teacher that did the same thing,when I asked why, what I got was "well would you <open ended philosophical question that meant less and less the more you thought about it>" to which I'd respond "... If it's more efficient"
-
unleashy227y@PRein Only if they've never worked with some sort of C99, because that allows the short initialization syntax.
-
If you need an argument why not to write the code in this way:
It violates the DRY principle (don't repeat yourself).
Related Rants
-
elgringo41Student - Teacher renaming .c to .exe make the program executable ? Teacher - Yes A group of people stand up...
-
kescherRant14Our programming teacher had a surgery on his left eye and will not be able to do the lessons with us. Guess wh...
-
sonrisa37Best quotes from IT teacher: - "C# is a language to program your IDE." - "C# is a language for beginners, and...
Our programming teacher always wanted us to do this (in C#):
somedatatype somevarname;
somevarname = somevalue;
You were NEVER allowed to:
somedatatype somevarname = somevalue;
"Can't I just do it in one line?"
"No."
"Why?"
"<insert dumb statement here that gives no reason whatsoever>"
undefined
but why
teacher