12 Replies - 1814 Views - Last Post: 25 February 2011 - 03:32 AM

#1 heyoman1  Icon User is offline

  • D.I.C Addict
  • member icon

Reputation: 64
  • View blog
  • Posts: 735
  • Joined: 30-November 09

Is it possible to cheat at programming?

Posted 23 February 2011 - 01:23 PM

Cheating, I believe, is taking the easy way out. But for some reason, I think I'm cheating at programming.

For example, my URL Shortener is pretty short for something that seems like a large topic. Most people would go to bit.ly pro or YOURLS to make their custom one, while mine is homemade. bit.ly and YOURLS use pages and pages of code to accomplish this, while I use a measly ~60 lines of code to (almost) the same thing (almost because of no URL tracking).

And then last night, I wrapped up finishing a note web app (I call it a diary). It took 8 pages and only 325 line of code to make. I received help with 2 database issues, and that's it.

To me, I just feel like I'm cheating at this, while other people work hard to bring this to other people. Should I be concerned about myself?

This post has been edited by heyoman1: 23 February 2011 - 01:24 PM


Is This A Good Question/Topic? 0
  • +

Replies To: Is it possible to cheat at programming?

#2 Dormilich  Icon User is online

  • 痛覚残留
  • member icon

Reputation: 3515
  • View blog
  • Posts: 10,146
  • Joined: 08-June 10

Re: Is it possible to cheat at programming?

Posted 23 February 2011 - 01:27 PM

two points:
- what makes you think code must be long and clunky?
- bit.ly & Co. certainly have a much larger user base
Was This Post Helpful? 0
  • +
  • -

#3 heyoman1  Icon User is offline

  • D.I.C Addict
  • member icon

Reputation: 64
  • View blog
  • Posts: 735
  • Joined: 30-November 09

Re: Is it possible to cheat at programming?

Posted 23 February 2011 - 01:32 PM

Quote

what makes you think code must be long and clunky?

Just seeing what it takes for someone else to do the same thing.
Was This Post Helpful? 0
  • +
  • -

#4 lordofduct  Icon User is offline

  • I'm a cheeseburger
  • member icon


Reputation: 2533
  • View blog
  • Posts: 4,633
  • Joined: 24-September 10

Re: Is it possible to cheat at programming?

Posted 23 February 2011 - 02:14 PM

*
POPULAR

ur url shortener is cool and all, but the reason most people use a database is it's easier to maintain, and faster to lookup against. Creating a file for each entry, or creating a line item list file, would quickly become absurdly slow as the number of entries grew.

The database also has room to expand, making it fast and easy to associate other data with entries, and reverse look-up both those values. (Say you associate a user who created think short url, and you want to look up who did so... you could write these into the files you make, but it would be hell to look up a file based on the user who created it).




Your code being shorter isn't a sign of you 'cheating'. It's a sign that you solved the problem in a different way. Not to say your way is worse or better (that's subjective)... just different. What you should be asking yourself when you see how these other people solve a similar problem is, "why do they solve it this way? What benefits did they gain?"

This isn't to say sometimes you may come across long winded code that serves no purpose. This depends on the quality of the coder, which is sometimes difficult to know, especially if you yourself are still only a beginner. It takes practice to understand why a Jackson Pollock is considered high art (of which I have no practice in and can't determine why it isn't just a splatter of paint).




What I would call 'cheating' is if you yourself didn't actually write the code, and you didn't understand the code either. Copy-pasting scripts from the internet and jerry-rigging them together. Going on forums and getting other members to write your code for you. Blatantly stealing code and sticking your name on it.

That's cheating.

May it be cheating others out of their credit... or cheating yourself out of proper knowledge and education.

This post has been edited by lordofduct: 23 February 2011 - 02:20 PM

Was This Post Helpful? 5
  • +
  • -

#5 hookiethe1  Icon User is offline

  • D.I.C Lover

Reputation: 416
  • View blog
  • Posts: 1,335
  • Joined: 28-September 10

Re: Is it possible to cheat at programming?

Posted 23 February 2011 - 02:38 PM

In this context, cheating could also refer to taking shortcuts. It may be the case that you are inherently able to write really elegant and efficient code that few others can, in which case, congratulations, you have a gift. But like LoD suggested, sometimes you need to do things the long way in order to write robust, scalable code. Not to completely rehash his post, but he is right when he says you should be looking to see if other people's longer codes are more flexible, stable, or scalable than yours.
Was This Post Helpful? 1
  • +
  • -

#6 heyoman1  Icon User is offline

  • D.I.C Addict
  • member icon

Reputation: 64
  • View blog
  • Posts: 735
  • Joined: 30-November 09

Re: Is it possible to cheat at programming?

Posted 23 February 2011 - 03:04 PM

After reading both of your posts, and some thinking, I guess when I'm programming, I just get straight to the point without thinking about any other aspect. Then when I do find out I need something else, just a quick fix, and it works. I understand what I type, thus me not commenting as much. I just think about what people are really going to do with this product, and based on feedback, make what they need.
Was This Post Helpful? 0
  • +
  • -

#7 Creecher  Icon User is offline

  • I don't care
  • member icon

Reputation: 561
  • View blog
  • Posts: 2,049
  • Joined: 06-March 10

Re: Is it possible to cheat at programming?

Posted 24 February 2011 - 06:40 AM

View Postheyoman1, on 23 February 2011 - 05:04 PM, said:

After reading both of your posts, and some thinking, I guess when I'm programming, I just get straight to the point without thinking about any other aspect. Then when I do find out I need something else, just a quick fix, and it works. I understand what I type, thus me not commenting as much. I just think about what people are really going to do with this product, and based on feedback, make what they need.

This is exactly what I do.

I hardly ever comment my own code, unless I'm sending to a teacher or colleague.

I never really thought of getting straight to the point as 'cheating' though, I always did it so I can get things done, and if I wanted to add something else, I'd add it and leave something else. For instance, I created a simple pastebin using only 2 pages and about 200(ish) lines of code, but when I wanted to add a "recently posted" section or whatever, I just went in, wrote the code, and it was done.
Was This Post Helpful? 1
  • +
  • -

#8 nooblet  Icon User is offline

  • D.I.C Addict

Reputation: 120
  • View blog
  • Posts: 541
  • Joined: 12-March 10

Re: Is it possible to cheat at programming?

Posted 24 February 2011 - 06:52 AM

I just want to say one thing for the OP... How you code something for a few people vs how you code something for a shitload of people varies a lot. Getting the code to behave the way you want it can be done in many ways but with scale, it drastically changes how you approach a problem. What works for 10 people may not work for 10 million.
Was This Post Helpful? 0
  • +
  • -

#9 Curtis Rutland  Icon User is offline

  • (╯□)╯︵ (~ .o.)~
  • member icon


Reputation: 4455
  • View blog
  • Posts: 7,760
  • Joined: 08-June 10

Re: Is it possible to cheat at programming?

Posted 24 February 2011 - 08:56 AM

View Postheyoman1, on 23 February 2011 - 04:04 PM, said:

After reading both of your posts, and some thinking, I guess when I'm programming, I just get straight to the point without thinking about any other aspect. Then when I do find out I need something else, just a quick fix, and it works. I understand what I type, thus me not commenting as much. I just think about what people are really going to do with this product, and based on feedback, make what they need.


You're describing the difference between a hobbyist working on projects and professionals working on large-scale applications.

Your URL shortener is a great example. It's very concise, for sure. It's not all that scalable, but for your personal use it doesn't need to be.

On the other hand, a URL service that literally millions of people use can't afford not to be scalable. They have to include lots of documentation and error checking and things like that. If your application breaks, the only one that loses anything is you, and all you lose is a bit of time fixing it. If bit.ly breaks, lots of people are in trouble.

It's a difference of style and necessity; however, if you ever plan on developing for a large-scale application, you should start building good habits now.
Was This Post Helpful? 4
  • +
  • -

#10 ForcedSterilizationsForAll  Icon User is offline

  • D.I.C Addict

Reputation: 33
  • View blog
  • Posts: 506
  • Joined: 16-July 09

Re: Is it possible to cheat at programming?

Posted 24 February 2011 - 01:56 PM

Yeah, it really depends on who is going to use/maintain your app. If it's for your own personal use then it doesn't matter.

Professionally, some of what you've described is really poor in terms of methodologies. Forgetting to make a change or needing to change something after you're a few hundred hours in can have a huge impact. The thing you forget could have a huge impact on the design and it's a lot easier to catch it in the beginning than late in the game.

However, it sounds like your stuff is more hobbyist work. In which case it doesn't really matter.
Was This Post Helpful? 0
  • +
  • -

#11 Craig328  Icon User is offline

  • I make this look good
  • member icon

Reputation: 1919
  • View blog
  • Posts: 3,461
  • Joined: 13-January 08

Re: Is it possible to cheat at programming?

Posted 24 February 2011 - 01:57 PM

View Postheyoman1, on 23 February 2011 - 05:04 PM, said:

After reading both of your posts, and some thinking, I guess when I'm programming, I just get straight to the point without thinking about any other aspect. Then when I do find out I need something else, just a quick fix, and it works. I understand what I type, thus me not commenting as much. I just think about what people are really going to do with this product, and based on feedback, make what they need.


Bad habits are bad.

By way of example I am trying to resurrect a site I took about 2 years to code in my spare time but which I haven't touched much at all in the past year. I can't tell you how much I'm hating not having commented sections of my own code. You THINK you'll remember what was on your mind at the time but believe me, you don't. This is especially true when you've progressed professionally past the point where you originally wrote your code. In my case, it's even worse as I've changed both underlying techs that drove the site (the platform and the database product) so I'm getting the extra added bonus of having to sort out "what the hell was I thinking" from "I know what I was thinking but this still isn't working".

Very educational. :)
Was This Post Helpful? 3
  • +
  • -

#12 Dormilich  Icon User is online

  • 痛覚残留
  • member icon

Reputation: 3515
  • View blog
  • Posts: 10,146
  • Joined: 08-June 10

Re: Is it possible to cheat at programming?

Posted 24 February 2011 - 11:18 PM

View PostCraig328, on 24 February 2011 - 09:57 PM, said:

By way of example I am trying to resurrect a site I took about 2 years to code in my spare time but which I haven't touched much at all in the past year. I can't tell you how much I'm hating not having commented sections of my own code. You THINK you'll remember what was on your mind at the time but believe me, you don't. This is especially true when you've progressed professionally past the point where you originally wrote your code. In my case, it's even worse as I've changed both underlying techs that drove the site (the platform and the database product) so I'm getting the extra added bonus of having to sort out "what the hell was I thinking" from "I know what I was thinking but this still isn't working".

Very educational. :)

a story to be read by all those who claim that it suffices to "get the code working" …

This post has been edited by Dormilich: 25 February 2011 - 03:37 AM

Was This Post Helpful? 0
  • +
  • -

#13 jeremejazz  Icon User is offline

  • New D.I.C Head
  • member icon

Reputation: 22
  • View blog
  • Posts: 48
  • Joined: 23-April 10

Re: Is it possible to cheat at programming?

Posted 25 February 2011 - 03:32 AM

is googling another way of cheating? :alucard:
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1