google "top coder" contest = stacked against C++ coders

Discussion in 'C++' started by ziliath, Sep 16, 2004.

  1. ziliath

    ziliath Guest

    I recently tried out the Google "top coder" contest, as a C++
    coder. I noticed immediately that they expected me to know STL.
    To which I say, what the ****?!

    I may be missing something, but at what point when learning C++
    was I supposed to have picked up STL? I ask because at every
    job I've had, and every job interview for that matter, whenever
    STL comes up it's not I, but a manager who says effectively
    yuck, we don't use that crap.

    To which I say good, I never learned that crap.

    Not that I haven't tried using it. The error messages that any
    newbie-to-STL is bound to get were 100+ lines long. Really useful!

    Google clearly has stacked their contest against C++ programmers,
    which means that it is not about "top coders" after all.
     
    ziliath, Sep 16, 2004
    #1
    1. Advertising

  2. ziliath

    who Guest

    The STL is part of the standard C++ language right? Then that's part of C++
    isn't it? So, if an exam of some type contains a series of questions
    regarding C++ programming it will have questions relating to the language
    right?

    The STL is taught at any introductory university course on C++ programming.
    Pickup an introductory C++ book these days and you'll be hard pressed to
    find one without details of it. It greatly simpilfies certain things in the
    language, but can be complex to some beginners. I'd rather be coding apps
    and libraries using the STL rather than reimplementing a hell of a lot of
    code that it already offers. It's not difficult to understand the basics.

    There are many companies where programmers use the STL, just because you
    haven't worked in one doesn't mean that they don't exist - right? =:)

    Regards,

    M
     
    who, Sep 16, 2004
    #2
    1. Advertising

  3. ziliath wrote:
    > I recently tried out the Google "top coder" contest, as a C++
    > coder. I noticed immediately that they expected me to know STL.
    > To which I say, what the ****?!
    >
    > I may be missing something, but at what point when learning C++
    > was I supposed to have picked up STL? I ask because at every
    > job I've had, and every job interview for that matter, whenever
    > STL comes up it's not I, but a manager who says effectively
    > yuck, we don't use that crap.
    >
    > To which I say good, I never learned that crap.
    >
    > Not that I haven't tried using it. The error messages that any
    > newbie-to-STL is bound to get were 100+ lines long. Really useful!
    >
    > Google clearly has stacked their contest against C++ programmers,
    > which means that it is not about "top coders" after all.


    The standard library included with any language is as valuable as the
    language itself. You can say that the C library is not technically part
    of the C language, so you needn't learn all that printf stuff, but you'd
    just be fooling yourself.

    I've learned to love the STL, and I use it occasionally, when the
    appropriate opportunity arises. But if you never learn it, you'd never
    know when it'll come in handy!
     
    Dave Rahardja, Sep 16, 2004
    #3
  4. "ziliath" <> wrote in message
    news:...
    >
    > [snip]


    Most C++ programmers know the STL. The contest is not stacked against C++
    programmers (as your misleading title says), but against any programmer that
    does not know the basics of the system library of the language they will be
    using.

    The probable reason for this is that you are not allowed to include any
    nonstandard headers. Should you be surprised? With non-standard headers,
    you can gain an advantage that others don't have. To prevent this, they
    level the playing field. You can try it without the STL, but good luck on
    actually doing anything productive. How are you even going to get input
    from the user?

    James
     
    Aguilar, James, Sep 16, 2004
    #4
  5. "ziliath" <> wrote in message
    news:...
    > I recently tried out the Google "top coder" contest, as a C++
    > coder. I noticed immediately that they expected me to know STL.
    > To which I say, what the ****?!


    I don't get it .... OH! you mean WTF. I've never seen it spelled out fully.

    > I may be missing something, but at what point when learning C++
    > was I supposed to have picked up STL? I ask because at every
    > job I've had, and every job interview for that matter, whenever
    > STL comes up it's not I, but a manager who says effectively
    > yuck, we don't use that crap.
    >
    > To which I say good, I never learned that crap.
    >
    > Not that I haven't tried using it. The error messages that any
    > newbie-to-STL is bound to get were 100+ lines long. Really useful!


    I guess you don't care about extensibility, reusability or genericity, and
    neither do any of your managers. Maybe you should get a new job.

    Jonathan
     
    Jonathan Turkanis, Sep 16, 2004
    #5
  6. ziliath

    David White Guest

    "ziliath" <> wrote in message
    news:...
    > I recently tried out the Google "top coder" contest, as a C++
    > coder. I noticed immediately that they expected me to know STL.
    > To which I say, what the ****?!


    Er, why? The STL is a part of C++.

    > I may be missing something, but at what point when learning C++
    > was I supposed to have picked up STL?


    Preferably in Lesson 1.

    > I ask because at every
    > job I've had, and every job interview for that matter, whenever
    > STL comes up it's not I, but a manager who says effectively
    > yuck, we don't use that crap.


    That's a bit difficult to understand, since the STL makes it very easy to do
    many useful things. Perhaps those managers would have been more truthful if
    they'd said, "We could never be bothered learning that crap, so we really
    wouldn't have a clue if it's crap or not." I suggest that the most competent
    C++ programmers would be less than impressed with such an attitude from a
    manager, and look elsewhere. Besides, you should never let managers near
    your code. :)

    > To which I say good, I never learned that crap.


    Then you missed a very important part of C++ when you learned it.

    > Not that I haven't tried using it. The error messages that any
    > newbie-to-STL is bound to get were 100+ lines long. Really useful!


    Yes, error message technology has fallen behind compiler technology, but
    with a bit of experimentation you can usually figure out what's wrong.

    > Google clearly has stacked their contest against C++ programmers,
    > which means that it is not about "top coders" after all.


    Sounds to me like they've stacked their contest in _favour_ of C++
    programmers.

    DW
     
    David White, Sep 16, 2004
    #6
  7. ziliath

    assaarpa Guest

    > I guess you don't care about extensibility, reusability or genericity, and
    > neither do any of your managers. Maybe you should get a new job.


    A common misconception.

    First, I acknowledge that the c++ does not know about dll's or Windows - but
    the Real World does! Use std containers to pass objects across dll
    boundaries and you crash and burn so beautifully.

    The work around is not to pass std containers across dll boundaries, and
    guess what? That means the reusability and genericity is thrown right out
    the door, you cannot just take c++ code someone written using std containers
    and plug it in (=reuse). Nope. What you have to do is fix this c++ God's
    mistakes and with that HE had taken that new job..
     
    assaarpa, Sep 16, 2004
    #7
  8. ziliath

    David Hilsee Guest

    "assaarpa" <> wrote in message
    news:cib505$6jq$...
    > > I guess you don't care about extensibility, reusability or genericity,

    and
    > > neither do any of your managers. Maybe you should get a new job.

    >
    > A common misconception.
    >
    > First, I acknowledge that the c++ does not know about dll's or Windows -

    but
    > the Real World does! Use std containers to pass objects across dll
    > boundaries and you crash and burn so beautifully.
    >
    > The work around is not to pass std containers across dll boundaries, and
    > guess what? That means the reusability and genericity is thrown right out
    > the door, you cannot just take c++ code someone written using std

    containers
    > and plug it in (=reuse). Nope. What you have to do is fix this c++ God's
    > mistakes and with that HE had taken that new job..

    <snip>

    First, let me point out that DLLs are platform-specific and off-topic. Now,
    having said that, I doubt that standard containers cause a huge headache
    when it comes to DLL boundaries. In the worst case (which I guess happens
    when a container cannot be passed across any interface for some odd reason),
    I would expect that there might be a need to convert the container into
    another type and then later convert it back into the container. That means
    that you have to write a function that transforms the container into
    something like an array or a linked list, and then you have to write a
    function that transforms it back. That's no big deal. Granted, if there is
    an issue, it helps to be aware of it before encountering it, but that's true
    of any problem. I don't think that means that reusability is "thrown right
    out the door."

    --
    David Hilsee
     
    David Hilsee, Sep 16, 2004
    #8
  9. "assaarpa" <> wrote in message
    news:cib505$6jq$...
    > > I guess you don't care about extensibility, reusability or genericity, and
    > > neither do any of your managers. Maybe you should get a new job.

    >
    > A common misconception.
    >
    > First, I acknowledge that the c++ does not know about dll's or Windows - but
    > the Real World does! Use std containers to pass objects across dll
    > boundaries and you crash and burn so beautifully.


    Passing objects between dll's is a general problem which doesn't have anything
    to do with STL.

    Jonathan
     
    Jonathan Turkanis, Sep 16, 2004
    #9
  10. "ziliath" <> wrote in message
    news:...
    | I recently tried out the Google "top coder" contest, as a C++
    | coder. I noticed immediately that they expected me to know STL.
    | To which I say, what the ****?!

    after all, this must be the biggest breakthrough in programming of the
    previsous decade.

    | I may be missing something, but at what point when learning C++
    | was I supposed to have picked up STL? I ask because at every
    | job I've had, and every job interview for that matter, whenever
    | STL comes up it's not I, but a manager who says effectively
    | yuck, we don't use that crap.

    clearly someone who didn't learned it either.

    | To which I say good, I never learned that crap.

    he he, bad for you. If you can't even use std::sort(), I guess you're in
    truoble.

    | Not that I haven't tried using it. The error messages that any
    | newbie-to-STL is bound to get were 100+ lines long. Really useful!

    This is often a mixture of compiler QoI and STL implementation. You also
    want to use an IDE that jumps to the line where the error is detected. And
    then
    you might want to check out STLfilt: http://www.bdsoft.com/tools/stlfilt.html

    | Google clearly has stacked their contest against C++ programmers,
    | which means that it is not about "top coders" after all.

    most programmers learn both languages and quickly discovers that Java is for
    toy programs.

    br

    Thorsten
     
    Thorsten Ottosen, Sep 16, 2004
    #10
  11. ziliath

    Tabrez Iqbal Guest

    (ziliath) wrote in message news:<>...
    > I recently tried out the Google "top coder" contest, as a C++
    > coder. I noticed immediately that they expected me to know STL.
    > To which I say, what the ****?!
    >
    > I may be missing something, but at what point when learning C++
    > was I supposed to have picked up STL? I ask because at every
    > job I've had, and every job interview for that matter, whenever
    > STL comes up it's not I, but a manager who says effectively
    > yuck, we don't use that crap.
    >
    > To which I say good, I never learned that crap.
    >
    > Not that I haven't tried using it. The error messages that any
    > newbie-to-STL is bound to get were 100+ lines long. Really useful!
    >
    > Google clearly has stacked their contest against C++ programmers,
    > which means that it is not about "top coders" after all.


    i don't think STL part of the Standard C++ is such a beast which
    should be avoided as long as possible. In fact you are much better
    startinf using it from your very first programs. Look what Stroustrup
    suggests as a sample program:

    http://www.research.att.com/~bs/bs_faq2.html#simple-program

    it uses both containers and algorithms.

    the people who say that they never learned the "crap" are using a very
    outdated version of C++ and run the risk of soon becoming "out-dated"
    themselves. You better follow other examples. I wonder which book(s)
    you followed while learning C++.

    tabrez
     
    Tabrez Iqbal, Sep 16, 2004
    #11
  12. ziliath

    JKop Guest

    ziliath posted:

    > I recently tried out the Google "top coder" contest, as a

    C++
    > coder. I noticed immediately that they expected me to

    know STL.
    > To which I say, what the ****?!
    >
    > I may be missing something, but at what point when

    learning C++
    > was I supposed to have picked up STL? I ask because at

    every
    > job I've had, and every job interview for that matter,

    whenever
    > STL comes up it's not I, but a manager who says

    effectively
    > yuck, we don't use that crap.
    >
    > To which I say good, I never learned that crap.
    >
    > Not that I haven't tried using it. The error messages

    that any
    > newbie-to-STL is bound to get were 100+ lines long.

    Really useful!
    >
    > Google clearly has stacked their contest against C++

    programmers,
    > which means that it is not about "top coders" after all.


    The STL is dead handy.

    Would you prefer spending an hour or so messing with
    strings, or just do:

    std::string blah = "hello" + something + " -" + otherstuff;

    I always use the STL in conjunction with Win32API.

    When I'm done messing with the string I simply:

    FindFirstFileEx( blah.c_str() );


    -JKop
     
    JKop, Sep 16, 2004
    #12

  13. > The STL is dead handy.
    >
    > Would you prefer spending an hour or so messing with
    > strings, or just do:
    >
    > std::string blah = "hello" + something + " -" + otherstuff;
    >
    > I always use the STL in conjunction with Win32API.
    >
    > When I'm done messing with the string I simply:
    >
    > FindFirstFileEx( blah.c_str() );


    Unfortunately I jumped into C++ programming using MFC. Now my code is
    full of CArray, CString and CFile. Great, MS. Now I have to rewrite
    piece by piece if I want to have it portable one day. Did you know
    that none of the MFC container classes has an = operator? It was the
    worst idea not to use STL by MS, and I got trapped. Don't do the same.
    Use the STL, it's really really a great thing.
     
    Gernot Frisch, Sep 16, 2004
    #13
  14. ziliath

    Old Wolf Guest

    (ziliath) wrote:
    > I recently tried out the Google "top coder" contest, as a C++
    > coder. I noticed immediately that they expected me to know STL.
    > To which I say, what the ****?!


    You seem to be a bit out of touch. This is akin to saying
    "I went for a programming interview for a C job and they
    expected me to know pointers. What the ****?"

    > I may be missing something, but at what point when learning C++
    > was I supposed to have picked up STL?


    The first day, I would hope.

    > I ask because at every
    > job I've had, and every job interview for that matter, whenever
    > STL comes up it's not I, but a manager who says effectively
    > yuck, we don't use that crap.


    The 1980s called, they want their C-with-classes back.

    > Not that I haven't tried using it. The error messages that any
    > newbie-to-STL is bound to get were 100+ lines long. Really useful!


    A poor workman blames his tools. Why don't you try learning
    from a book or a tutor, rather than "trial-and-error" self-teaching?
    How about if I said that foreign (spoken) languages were stupid
    because when I try them out I get error messages I can't understand?
     
    Old Wolf, Sep 16, 2004
    #14
  15. Gernot Frisch wrote:

    > Unfortunately I jumped into C++ programming using MFC. Now my code is
    > full of CArray, CString and CFile. Great, MS. Now I have to rewrite
    > piece by piece if I want to have it portable one day. Did you know
    > that none of the MFC container classes has an = operator? It was the
    > worst idea not to use STL by MS, and I got trapped.


    MFC is older than the STL. When the first version of MFC was released
    there was no standard library and at the time it had to be compiled on
    compilers that supported little more than "C with classes". Visual C++
    1.0 had no support for templates, exceptions, RTTI...etc, in fact it had
    little in common with what we today consider to be C++. If you turn the
    clock twelve years back, many of the choices the MFC developers made are
    understandable. But from todays point of view MFC is a load of obsolete
    crap.

    > Don't do the same.
    > Use the STL, it's really really a great thing.


    Agreed, having been in a situation where I couldn't use the standard
    library and having been forced to use alternatives solutions I can tell
    that the standard library (often) makes life so much easier and more
    productive.

    --
    Peter van Merkerk
    peter.van.merkerk(at)dse.nl
     
    Peter van Merkerk, Sep 16, 2004
    #15
  16. In article <PB72d.32392$>, who
    <> writes
    >There are many companies where programmers use the STL, just because you
    >haven't worked in one doesn't mean that they don't exist - right? =:)


    And with the attitude he has, he is unlikely to work for a company that
    uses the Standard C++ Library.


    --
    Francis Glassborow ACCU
    Author of 'You Can Do It!' see http://www.spellen.org/youcandoit
    For project ideas and contributions: http://www.spellen.org/youcandoit/projects
     
    Francis Glassborow, Sep 16, 2004
    #16
  17. ziliath

    Alex Vinokur Guest

    Alex Vinokur, Sep 16, 2004
    #17
  18. ziliath

    assaarpa Guest

    > First, let me point out that DLLs are platform-specific and off-topic.
    Now,

    <snip> Let me remind that saying that someone should get a new job, because
    he works in the real world and not the fantasy world here, is also
    off-topic. Nuff said.


    > that you have to write a function that transforms the container into
    > something like an array or a linked list, and then you have to write a
    > function that transforms it back. That's no big deal. Granted, if there

    is
    > an issue, it helps to be aware of it before encountering it, but that's

    true
    > of any problem. I don't think that means that reusability is "thrown

    right
    > out the door."


    Yes, it is.

    std::string foo();

    If you call that method across dll boundary, you crash and burn. Bye bye
    reusability. QED.
     
    assaarpa, Sep 16, 2004
    #18
  19. ziliath

    assaarpa Guest

    > Passing objects between dll's is a general problem which doesn't have
    anything
    > to do with STL.


    If you write "reusable" code with STL, it won't be reusable in that domain
    but will crash and if you don't know your trade but just blindly trust the
    STL to work correctly (hey, according to the standard it is valid code) it
    WILL fail, so much for reusability. This means you cannot just take code
    some top gun c++ programmer wrote and reuse it. Something the standard
    library just isn't very good for, sorry to break the news but it isn't
    perfect for everything.
     
    assaarpa, Sep 16, 2004
    #19
  20. assaarpa wrote:

    >>of any problem. I don't think that means that reusability is "thrown
    >> right out the door."

    >
    > Yes, it is.
    >
    > std::string foo();
    >
    > If you call that method across dll boundary, you crash and burn. Bye bye
    > reusability. QED.


    Funny, I'm working large scale project which does exactly that, and a
    lot. It doesn't crash and burn. But I admit you do have know what you
    are doing (or to be more precise what happens under the hood) to get it
    right.

    Anyway this problem is not related to the STL. Passing C++ objects
    (including homebrew ones) across DLL boundaries is always tricky
    business. And if you compile the .exe and .dll with different compilers
    you can forget it, because there is no standardized ABI for C++.

    --
    Peter van Merkerk
    peter.van.merkerk(at)dse.nl
     
    Peter van Merkerk, Sep 16, 2004
    #20
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Dietmar Kuehl
    Replies:
    0
    Views:
    858
    Dietmar Kuehl
    Sep 16, 2004
  2. DevNull
    Replies:
    7
    Views:
    461
    kwikius
    Feb 27, 2007
  3. Jimmy

    Sorting on *stacked* data using webforms datagrid

    Jimmy, Feb 26, 2005, in forum: ASP .Net Datagrid Control
    Replies:
    0
    Views:
    104
    Jimmy
    Feb 26, 2005
  4. Jorge Rodriguez

    Scruffy Stacked Bar help

    Jorge Rodriguez, Jun 7, 2007, in forum: Ruby
    Replies:
    0
    Views:
    95
    Jorge Rodriguez
    Jun 7, 2007
  5. Robert Kern
    Replies:
    0
    Views:
    106
    Robert Kern
    Sep 25, 2013
Loading...

Share This Page