Hungarian Notation

This is a discussion on Hungarian Notation within the A Brief History of Cprogramming.com forums, part of the Community Boards category; Do you hate Hungarian Notation?...

  1. #1
    .
    Join Date
    Aug 2001
    Posts
    598

    Hungarian Notation

    Do you hate Hungarian Notation?
    To Err Is To Be Human. To Game Is Divine!"

  2. #2
    .
    Join Date
    Aug 2001
    Posts
    598
    I find it very stupid, annoying and hard to read.
    To Err Is To Be Human. To Game Is Divine!"

  3. #3
    l'Anziano DavidP's Avatar
    Join Date
    Aug 2001
    Location
    Plano, Texas, United States
    Posts
    2,738
    remember my old sig?

    "A duck is a duck. There is no excuse for Hungarian notation."

    Maybe I should use it again...
    My Website

    "Circular logic is good because it is."

  4. #4
    & the hat of GPL slaying Thantos's Avatar
    Join Date
    Sep 2001
    Posts
    5,681
    Ok have to ask. What the heck is Hungarian Notation?

  5. #5
    Just one more wrong move. -KEN-'s Avatar
    Join Date
    Aug 2001
    Posts
    3,230
    it was a HORSE, not a duck!

  6. #6
    l'Anziano DavidP's Avatar
    Join Date
    Aug 2001
    Location
    Plano, Texas, United States
    Posts
    2,738
    lol...it was, wasnt? i cant even remember my own old sig correctly...
    My Website

    "Circular logic is good because it is."

  7. #7
    .
    Join Date
    Aug 2001
    Posts
    598
    > What the heck is Hungarian Notation?

    instead of declaring varbles like this

    unsigned int *Whatever

    you do this

    unsinged int *dwlWhatever

    It was created by microsoft to reduce errors. Can you see why no one likes it?
    To Err Is To Be Human. To Game Is Divine!"

  8. #8
    l'Anziano DavidP's Avatar
    Join Date
    Aug 2001
    Location
    Plano, Texas, United States
    Posts
    2,738
    Hungarian notation:

    HWND hwnd;

    What it SHOULD be:

    WINDOWHANDLE myWindowHandle;

    Hungarian notation:

    int __mf__dck_;

    What it SHOULD be:

    int Duck;
    My Website

    "Circular logic is good because it is."

  9. #9
    Linguistic Engineer... doubleanti's Avatar
    Join Date
    Aug 2001
    Location
    CA
    Posts
    2,459
    yeah, a horse... and who keeps so many exclusively-named variables in a block of code that they would need such a notation anyway!
    hasafraggin shizigishin oppashigger...

  10. #10
    & the hat of GPL slaying Thantos's Avatar
    Join Date
    Sep 2001
    Posts
    5,681
    Ok I understand what it is now. Thanks.

    BTW

    Its a piece of ****

  11. #11
    the hat of redundancy hat nvoigt's Avatar
    Join Date
    Aug 2001
    Location
    Hannover, Germany
    Posts
    3,139
    >A horse is a horse.

    Depending on your environment, a horse might also be a
    COrse handle. Anyway, the only good reason for not using
    it comes from adrianxw, who says todays IDEs will show
    the datatype anyway in a tooltip text or similar.

    "I don't like it" is not an excuse for larger programs in team
    environments. If you create a class CProject, what do you think
    how many myProjects will float around in such a project ?
    Ever thought about what happens if you want to look for
    instances of *your* myProject ? Goodbye SearchAndReplace or
    even Find. Why not name it after what it is, projXXX ( where X
    is the name ) ? There is a difference between lpszString and
    strString.

    It's a code. A standard. You don't have to follow it, but if all
    in your team do, it really speeds up debugging.
    hth
    -nv

    She was so Blonde, she spent 20 minutes looking at the orange juice can because it said "Concentrate."

    When in doubt, read the FAQ.
    Then ask a smart question.

  12. #12
    the hat of redundancy hat nvoigt's Avatar
    Join Date
    Aug 2001
    Location
    Hannover, Germany
    Posts
    3,139
    >Hungarian notation:
    >int __mf__dck_;

    >What it SHOULD be:
    >int Duck;


    NO !

    Hungarian notation of it would be

    int nDuck;
    hth
    -nv

    She was so Blonde, she spent 20 minutes looking at the orange juice can because it said "Concentrate."

    When in doubt, read the FAQ.
    Then ask a smart question.

  13. #13
    It's full of stars adrianxw's Avatar
    Join Date
    Aug 2001
    Posts
    4,831
    I don't like it. I have always put a lower case p in front of pointers, and I tend to use a "h" in front of handles but that is it.

    In the past there may have been a case for this kind of rubbish, but with todays IDE's, if I am not sure what type a variable is, I put my cursor over it, it tells me its type, offers to take me to it's declaration, and what it's current value is.
    Wave upon wave of demented avengers march cheerfully out of obscurity unto the dream.

  14. #14
    Registered User rick barclay's Avatar
    Join Date
    Aug 2001
    Posts
    835
    Shouldn't we be calling it Redmond notation? I think we do the
    Hungarians a great injustice with this.

    rick barclay
    No. Wait. Don't hang up!

    This is America calling!

  15. #15
    Former Member
    Join Date
    Oct 2001
    Posts
    955
    it is called Hungarian notation because it was invented by some guy at Microsoft who happened to be hungarian, I am currently at school, but this afternnon I can get the exact name of the guy

    Oskilian

Page 1 of 2 12 LastLast
Popular pages Recent additions subscribe to a feed

Similar Threads

  1. hungarian notation
    By KIBO in forum General Discussions
    Replies: 61
    Last Post: 01-11-2010, 10:42 PM
  2. CamelCase VS Hungarian notation, which is better?
    By meili100 in forum C++ Programming
    Replies: 4
    Last Post: 04-22-2007, 09:31 PM
  3. Hungarian Notation
    By FOOTOO in forum C Programming
    Replies: 6
    Last Post: 05-20-2005, 08:35 PM
  4. Hungarian Notation POLL
    By maxhavoc in forum A Brief History of Cprogramming.com
    Replies: 13
    Last Post: 06-21-2004, 10:52 AM
  5. hungarian notation
    By confuted in forum C++ Programming
    Replies: 2
    Last Post: 07-28-2003, 01:19 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21