Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon.

Pages: 1-4041-

worst advice for starting programmers

Name: Anonymous 2008-10-05 16:24

do you have common knowledge of programing? or are you starting from square one?

If you have a understanding of structuring a language then go ahead and jump into something like Visual Basic or C++, depending if you want to program object oriented or not...

but if you have no knowledge, start with something easy like Pascal, just to learn how to structure things...

Alex broke it down pretty well...

Name: Anonymous 2008-10-05 16:27

my university's Undergraduate Computer Science Degree program is one of the best in the nation (Baylor University) and we learn C++ first, followed by 80x86 Assembly Language and Java. Also our Video Game Development club (run by 3 of the CompSci professors) uses Game Maker 7 as our primary tool.

Name: Anonymous 2008-10-05 16:28

<=> is commonly called the ``Spaceship Operator''.

Name: Anonymous 2008-10-05 16:30

Anything that implies doing something that's not reading SICP.

Name: Anonymous 2008-10-05 17:55

Why Pascal is not my favorite Language

Name: Anonymous 2008-10-05 19:02

You should start learning PHP. It is easy for novices to start writing dynamic database driven websites with only basic knowledge of HTML. You can also start contributing extensions to popular open source projects like Joomla! and Drupal.

Name: Anonymous 2008-10-05 20:52

Be sure to write your own wrappers for all APIs no matter how trivial. And to be sure, wrap the wrappers as well.
int MyBeep()
{
   Beep();
}

Also, never use magic numbers
for(i = 0; i < 10; i++) //NO! BAD!!!

for(i = ZERO; i > TEN, i++) //PERFECT

Name: Anonymous 2008-10-05 21:01

Read Design Patterns: Elements of Reusable Object-Oriented Software.

Name: Anonymous 2008-10-06 15:29

>>8
Wins the thread. There's no single worst advice one could give.

Name: Anonymous 2008-10-06 15:32

Read Head First Design Patterns.

Name: Anonymous 2008-10-06 16:00

I've just started learning C in uni and it's not easy. One small mistake and it wont compile. Also it's just not logical whatsoever.

Name: Anonymous 2008-10-06 16:01

Read Sicp.

Name: Anonymous 2008-10-06 16:11

Read /prog/, they're smart people and can teach you a thing or two.

Name: Anonymous 2008-10-06 16:22

Always prefix the name of your variables with the type of variable they are. Example:

boolean boolean1;

Name: Anonymous 2008-10-06 16:26

>>11
C may be hard for you at first, but don't worry, once you've gotten the basics of it, then you will be able to move on to more respectable languages like Javascript.

Name: Anonymous 2008-10-06 16:54

Learn Systems Hungarian and use it in every project no matter what anyone else says.

Indent your code using three spaces.

Name: Anonymous 2008-10-06 17:42

javascrip programming language research by alan gay the faggot who sucks.

Name: Anonymous 2008-10-06 18:04

>>14
don't forget to add the description in the name too, it makes debugging easier!

boolean boolean___boolret___used_for_storing_return_values = false;

Name: Anonymous 2008-10-06 19:36

>>11
C's syntax was designed to be as easy to parse as possible.  I have no idea how they got from that goal to the sheer amount of ambiguity C syntax contains.

Name: Anonymous 2008-10-06 21:23

>>19
My guess is that it was actually B that was meant to be as easy to parse as possible, but the extra features that turned it into C (mainly the type system) also brought ambiguity into the language.

Name: Anonymous 2008-10-06 21:35

>>2
SIC'EM BEARS!

but sage for mentioning Baylor on /prog/

please don't sully our name again.

Name: Anonymous 2008-10-06 22:28

>>11
One small mistake and it wont compile.
Tell me again why you want broken programs to compile without complaint?

Name: Anonymous 2008-10-07 0:20

>>22
Because he's an expert PHP developer.

Name: Anonymous 2008-10-07 0:36

Get a dog, name it Haskell.

Name: Anonymous 2008-10-07 1:30

>>11
it's just not logical whatsoever
try Prolog

Name: Anonymous 2008-10-07 2:03

>>24
Feed it chocolate. Seriously, I bet that's what Haskell's owner did, but he's not man enough to admit so he blames it on a fictional old lady who dislikes dogs.

Name: Anonymous 2008-10-07 4:11

>>25
lets be logic

Name: Anonymous 2008-10-07 6:53

use M-x vip-mode

Name: Anonymous 2008-10-07 6:58

>>26
He fed her uranium.

Name: Anonymous 2008-10-07 12:22

>>22
I think you should read the subject of the thread one more time.

Name: Anonymous 2008-10-07 13:24

Awful advice for beginers:

-Start with C. You will learn how to program "right."

-If you want to learn Object Oriented Programming learn C++. (too many of you don't understand that C++ isn't an object oriented language. It is a language provides object oriented extensions that let you implement object oriented concepts yourself. There is an important distinction there.)

-Learn Java.

-If you want to do web development learn PHP.

>>7

Faggot, 0 and 1 are not magic numbers. But 10 (despite having both 0 and 1) is in case you are unclear about that. But in all honesty, if you did put yourself in a place where it seems like using a magic number is needed, then you did something terrible wrong and you need to stop programing.

Name: Anonymous 2008-10-07 13:28

0 and 1 are magic numbers in perl because they don't produce warning when used in void context.

Name: Anonymous 2008-10-07 14:52

>>32

Different kind of magic number.

In this context it means some non-obvious constant whose value is significant to the operation of a program and that is inserted inconspicuously in-line (hard-coded).

1 and 0 aren't as their use is usually very obvious. True/False, an increementor and so on.

In your context it is a magic number for perl, because perl lacks a no-op operator. Their use in perl should be obvious for people who know shit about perl.

Name: Anonymous 2008-10-07 15:08

>>33
I know Perl is shit, and their use is not obvious to me.

Name: Anonymous 2008-10-07 17:36

>>33
perl lacks a no-op operator
;  # VALID PERL CODE

Name: Anonymous 2008-10-07 18:46

Learn Visual Basic

Name: Anonymous 2008-10-07 18:56

int x;;;;;;;;;;;;     // VALID JAVA CODE

Name: Anonymous 2008-10-07 18:59

>>34
That's because you're a moron, on both counts.

Name: Anonymous 2008-10-08 12:32

start your programming career by learning VB.

Name: Anonymous 2008-10-08 14:08

>>35
  if 1; # invalid perl code
1 if 1; # valid perl code

Name: Anonymous 2008-10-08 14:12

I wonder if people are confusing VB and VB.Net.
VB has been functionally dead (read: legacy) for 7 years now.
VB.Net is a new language based on the VB syntax.
There is a new version of VB comming out but it is focused on being a scripting language.

It would not be bad advice to tell someone to start programming with VB.Net and the .Net framework.
-It is a proper class based OOP language.
-The library is extensive, useful, source code availble and not faggy like Java's. Seriously, JButton (JavaButton). JButton as opposed to what? CButton? Fuck proper namespace useage.
-It is cross platform, kinda. The .Net CLR is a publshed standard and so is C#. VB.Net just isn't part of that but compiled code will run on other platforms with something like Mono.
-You can use it to make desktop apps, web apps (with an extensive framework for that), mobile apps etc.
-Your knoweldge of the .Net framework does not go to waste with other languages as 25+ are supported.
-You can actually get a job with it.

Name: Anonymous 2008-10-08 14:22

>It would not be bad advice to tell someone to start programming with VB.Net and the .Net framework.

I lol'd heartily

Name: Anonymous 2008-10-08 15:03

-It is a proper class based OOP language.
Wonderful, more newbies who think OOP is da bestest.

Name: Anonymous 2008-10-08 15:28

>>43
Just ignore them until they realise that OOP is not the only way to do things

Name: Anonymous 2008-10-08 16:29

Seriously, JButton (JavaButton).
No, JButton (Swing) as opposed to Button (AWT, which predates Swing).

If you weren't completely ignorant of the history and philosophy of the Java language, you would understand.

Name: Anonymous 2008-10-08 16:41

Little-known fact: the J in all Swing classes stands for JUDAISM.

Name: Anonymous 2008-10-08 16:56

>>45
What the fuck does J have to do with Swing?

Name: Anonymous 2008-10-08 17:09

>>47
Swing is Java's standard GUI toolset. It really isn't that difficult.

Name: Anonymous 2008-10-08 17:36

>>48
a) You have been trolled by >>47.
b) >>47 is stupid.

Name: Anonymous 2008-10-08 20:16

>>49
Or, possibly,
c) >>48-49 are ignorant of J[1]

[m]----
[1] - J Home http://www.jsoftware.com/

Name: Anonymous 2008-10-08 20:17

MY EYES! THE GOOGLES DOES NOTHING

Name: Anonymous 2008-10-08 20:25

>>43
>>43

Self indulgent shit heads. No one said OOP was the only way. The idea here was that if you were gonna OOP, you should OOP correctly. Was that simple sentance too hard for you to understand.

>>45

If you weren't completley ignorant to what makes a good library you would understand the stupidity of naming a button jbutton and not a more descriptive name like button because that is what the fuck it is. Or can java devs not namespace correctly. Why call it an int, when we can call it a jint!

Name: Anonymous 2008-10-08 21:46

>>48
But AWT was Java's standard GUI toolset beforehand.  It's no less Java than Swing.  The whole J prefix is just fucking stupid and inconsistent.  They could have at least used S or Sw for a prefix, that would have made SOME sense.

Name: Anonymous 2008-10-08 22:23

>>52
You listed OOP as its selling point. Be more clearer.

Name: Anonymous 2008-10-08 22:42

>>52
Jesus Christ, do I have to spell everything out for you people? AWT was the standard widget toolkit for Java 1.0. It turned out to be unpopular, so was effectively superseded by Swing in 1.2. Now you can't expect everyone to go around calling everything by the fully qualified names javax.swing.Button and java.awt.Button, can you? Hence JButton. Why the J? Because Swing is now the de facto widget toolkit in Java. Case closed.

Name: Anonymous 2008-10-08 23:35

>>55
Yeah, but what was wrong with SButton? Because Swing is now the de facto widget toolkit in Java.

Name: Anonymous 2008-10-08 23:36

>>55 drank the kool-aid

Name: Anonymous 2008-10-08 23:47

>>57
There are a lot of legitimate criticisms of Java in general and Swing in particular, but the naming of classes is a very silly one. All focusing on it demonstrates is an ignorance of the actual problems.

Name: Anonymous 2008-10-08 23:49

>>55
Namespaces exist to never be used.  Got it.

Name: Anonymous 2008-10-08 23:51

>>56
No, Swing is now the de facto widget toolkit in Java.

Name: Anonymous 2008-10-09 0:11

>>55
Maybe they should have corrected the libraries so that you wouldn't need to use AWT and Swing simultaneously, thereby avoiding collisions. Or maybe Java should have a kick-ass module system like Haskell's, which allows you to explicitly hide imports.

Name: Anonymous 2008-10-09 2:31

>>54

The point is, if you OOP at least do it correctly. Unfortunately what is correct OOP is up for debate. But there are some fundamentals. One is that there are different kinds of OOP. VB.Net and C# are class based OOP. Everything is an object with them, a fundamental. And there are a host of others. I am not saying they do it the best and they are the only ones. There could be a huge discussion about this and it ends with Smalltalk basically being the only true OOP language because it was created to be exactly that. The point is, at least as of right now, it is a correct class based OOP language.

>>55

So now swing is the de facto. What happens when a new de facto comes out? Impossible you say, well it did happen before. Will we have J2Button?


>>58

You are very correct. I wanted to be quick and succinct and mention a very basic problem. If they can't even name their GUI widgets correctly, you can easily see how there would be many other problems. Like I said, J2Button or maybe JEnterpriseExtremeButton (or similar) is inevitable.

You wanna know another problem with Java that I hinted at, the Java Framework is tied to the Java language. I know other languages have been tacked on with much effort (and no popularity) and Sun has been working hard for a long time now to get dynamic languages on it and apparently failing. At least .Net is not tied to a language, they just released 2 similar languages with 2 familiar syntaxes with it. The .Net CLR and C# were open standards before Sun did the same with Java.

You wanna create an ASP.Net site totally in Python, you certainly can (with visual studio support or without). You want to dynamically compile a block of Python code that dynamically compiles and calls a JavaScript method from C# while all use the base .Net libraries and/or libraries you created in VB.Net? You can do that too.

Can you nativley do that in Java? No.

You wanna create some performant generic/templated functions in Java? No. You certainly can create them, but they have less performance due to the fucking awful concept of type erasure. Let's just incur extra boxing and unboxing instructions all day long.

And those are some of the fundamental very base problems with it. We can delve deeper in a new topic.

But still I wouldn't say telling a noob to learn Java is terrible advice. But there are better alternatives.

Name: Anonymous 2008-10-09 13:18

>>62
No, if that ever happens, we will have JJButton.

Name: Anonymous 2008-10-09 13:26

You wanna create some performant generic/templated functions in Java? No. You certainly can create them, but they have less performance due to the fucking awful concept of type erasure.
What? Erasure means that all that type information only has to be processed at compile time. At runtime you can use pure types, which is faster.

Name: Anonymous 2008-10-09 13:35

>>63
0/10

Name: Anonymous 2008-10-09 14:43

you should maybe figure out what type of programing connects with you better... you know the one that you can look at and somewhat make since of it with out ever running it

Name: Anonymous 2008-10-09 15:22

>>62
Clojure.

As goofy as Java is, the JVM is a stunning piece of technology.

Name: Anonymous 2008-10-10 2:21

If the code was hard to write, it should also be hard to read.

Name: Anonymous 2008-10-10 8:46

JAVA

Name: Anonymous 2011-02-03 2:10


Don't change these.
Name: Email:
Entire Thread Thread List