Slashdot Mirror


User: sht_london

sht_london's activity in the archive.

Stories
0
Comments
6
First seen
Last seen
Profile
(view on slashdot.org)

Comments · 6

  1. Re:Command and source/test review. on Java Faster Than C++? · · Score: 1

    std::string makes programming more convienent to write, but is not faster than an old-fashioned pointer to char. Normally direct manipulations of (char * ) are faster, but more diffucult to handle (memory leaks, allocation, free etc. pp.).
    Perhaps anyone can correct my: But so far I know the most std::string impementations use in the background the still (char *).

  2. YesAndNo on Java Faster Than C++? · · Score: 1

    Of course it possible to transform a function of the type

    a_n+1 := f (a_n) into a_n := g (a_0, n) This is not the question. By using a recursion the problem is: Does it makes sense: How much Stack I will need in worst case scenario? How much the calls, pops and pushs will effect the performance? Is it worth to pay this prize? Often enough I would say: Yes, but not always.

  3. Re:Matrices on Java Faster Than C++? · · Score: 1

    The "self-calculations" has an other benefit: If have class (template) administrating such a multi-dimensional array, the access calculation method can include checks against dynamical boundaries violations which can produce an error message/exception etc. - A very usefull "side-effect"

  4. Re:Matrices on Java Faster Than C++? · · Score: 1

    They shall/should, but you can not be sure - therefore it just better to make it on your own

  5. Matrices on Java Faster Than C++? · · Score: 1

    I had only a brief in the handling of the example code for matrix.cpp file. This code a fine example to slower the performance of code. It is always a bad idea to handle a matrix as a two-dimensional array. Doing so will cause the processor to performe complex calcumaltion of the size of the object. Any experienced coder would use a simple array and small method to calulate the position Something like
    return (iPos_x + iPos_y * iCount_x)

  6. Re:What about Pascal? on Programming For Terrified Adults? · · Score: 1

    I must support Pascal as a first programming language. Honestly: My C++ still looks a lot like Pascal ... Also: Pascal restricts the worst things to do and has a strikt type check - always a benefit.