Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

I'm feeling a little...... frustrated.....

 
Janeice DelVecchio
Saloon Keeper
Posts: 1808
12
Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm in college. I just worked my butt off for 6 credits in Java programming...

I understand syntax, loops, OO concepts, basic JDBC concepts, design patterns... I can use the API... I can find answers when I'm not sure there are any.

But they don't teach you how to write code... this way... in school. You learn how to make it work. Sometimes, the more lines the better.
I learned that if there's more than a couple lines in a row not commented, you must not know what you're doing and no one else will either.

I just wish college taught real life things like making readable code. Or at least suggested it as a concept.

Looking at what my latest submission turned into from what it was made me realize how frustrating this is to have to learn "again" instead of learn "the first time".

/vent

Thanks for listening.... any feelings are welcome and appreciated.
 
Marilyn de Queiroz
Sheriff
Posts: 9059
12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I can so totally empathize.
 
Maneesh Godbole
Saloon Keeper
Posts: 11021
12
Android Eclipse IDE Google Web Toolkit Java Mac Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well you can take a peek at this http://www.javaranch.com/style.jsp
These are more of guidelines. Every company will have their own guidelines, but the core will be similar to defined in the above link.

Sometimes, the more lines the better.
Well this will always work if you are getting paid by number of lines of code
While writing code, I always try and follow the KISS principle. Always keep the code simple and easy to understand.

Take a peek at the java source code. That is one of the examples how good code should be written.
 
Gary Ba
Ranch Hand
Posts: 161
Firefox Browser Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am definitely with you on this one. Sometimes students do not have plenty of time to program so they make it want to JUST work and then move on to the next one. Maybe you can suggest to the class that there should a guideline (like the one we use here) for writing code. Wait...thinking about it. That might actually be covered on another class.

my ten cents
 
Janeice DelVecchio
Saloon Keeper
Posts: 1808
12
Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for everyone's input....

I'm just holding onto "what does not kill me will make me stronger"

.... and hoping that other entry level graduates just won't be able to compete for a job with all my new fancy tricks
 
W. Joe Smith
Ranch Hand
Posts: 710
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I wasn't a computer science major, I was a management information systems major, but we still had some coding experience. I had the same type of experience as you. We could write the most convoluted, hard to read, terrible code and as long as it worked we got most of the points. There were some points taken off for lack of documentation, which was really just comments in code saying "Calculate interest" and things like that. Otherwise the majority of my professors would just run test data through our programs and if they worked properly then we were good. Of course, I'm slightly obsessive about code styling, and not having proper naming conventions/indendation/useful variable names and the like drives me crazy....
 
Katrina Owen
Sheriff
Posts: 1367
18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I spent TONS of time on my programming assignments in college, but there was no guidance as to how to do something better. We didn't learn anything about how to break problems down, how to debug, or any sort of best practices whatsoever.

Then I found the Cattle Drive and learned more in 20 lines of code than I had in months of classes and assignments.

In three words: Readability, readability, readability...
There is so much more to readability than formatting!
 
Janeice DelVecchio
Saloon Keeper
Posts: 1808
12
Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm totally learning a lot.... and it really helps to have a real person to ask questions because all my classes were online so I am all but self taught. I mean, except all the discussion I got here in the Saloon.... It made me pretty good at figuring things out, but I never felt like any real person looked at my code (even though they did).

Everything I've submitted works... except the time I thought I was being slick and edited something with a billion parenthesis in my email. And if I were smarter about testing (working on it...), I could even have made these things *functionally* flawless out of the gate. But they're not GOOD. As the matter of fact, making them GOOD is harder than the original coding. Figuring out why something isn't good is pretty hard, too.

The worst part is, it's like things are so obvious when they're pointed out.... and I say to myself, "wow... that was dumb... I didn't even notice." And I sit there on the next submission.... for a while.... and I stew about it. And I REALLY feel like it's the best... perfect even.

And then, I have a little bird who emails back and politely tells me, down to the letter, how it sucks.
... and she's right.

I'm just wondering when I'm going to not feel like it's so HARD to make things EASY.
 
Katrina Owen
Sheriff
Posts: 1367
18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Janeice DelVecchio wrote:
I'm just wondering when I'm going to not feel like it's so HARD to make things EASY.


I still think its hard to make things easy... but not quite as hard as it used to be. Certain things become habit. I don't find good names on the first try yet (maybe I never will), but I'm a bit better at it than I was, and I generally keep thinking about things to find better names.

Right now a friend of mine gave me the bowling kata from approvalstest.com and it p0wning me! It's great fun, and I got the test passing (a.k.a. "to green")... but holy schmoly my code is ugly. And I'm sitting here thinking there HAS to be a better way. And then I move something down, make a new method, get rid of a redundant line, rename a variable... and... zomg - UGLY. So, yeah
 
Ian Lubelsky
Ranch Hand
Posts: 49
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Janeice, remember nothing worth doing or having is ever easy. If everything was easy to do, everyone would be doing it. Also, what you think is hard today, will be simple tomorrow or at least easier.

My teachers and professors at times seemed more concerned with covering every single subject matter for the exams, than ensuring we were truly understanding what they were trying to teach us. That we weren't just memorizing something and spewing it back at them come exam time. In some of my classes I either spewed back their info to them as they "taught" us or I was not going to pass.

I remember when I was taking my I.T. courses, we'd move from one topic to the next without so much as a breath in between. What I was learning in school was the knowledge, but not exactly how this knowledge should best be applied. I quickly learned once I started working that what I learned in school was the ideal way of doing things, but was not necessarily the way things worked in the real world. You take what you learn in school and through experience, learn how to apply that knowledge to make your job easier and better.
 
paul wheaton
Trailboss
Pie
Posts: 21346
Firefox Browser IntelliJ IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Janeice DelVecchio wrote:
I'm just holding onto "what does not kill me will make me stronger"


Hmmmm .... a few cookies wouldn't will me ....

(later) .... now I feel strong enough to finish the whole box!

 
paul wheaton
Trailboss
Pie
Posts: 21346
Firefox Browser IntelliJ IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Different folks have different ways of trying to convey what is in their head into your head. And a lot of times, it really has little to do with your education as it does with your wallet: how to get 400,000 students to believe that the $120,000 they've parted with has left them more knowledgeable.

Nitpicking takes a lot of time.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic