CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com

Search:

Type: Posts; User: wolle

Page 1 of 29 1 2 3 4

Search: Search took 0.02 seconds; generated 55 minute(s) ago.

  1. Re: use of algorithms in function cause ERROR: no instance of overloaded function

    I have never tried it before, but std::span of C++ 20 seems a nice way of using C-style arrays with the standard library. An advantage is that it works with std::vector and std::array too.
    ...
  2. Replies
    7
    Views
    478

    Re: Convert C++ Code to Java

    Oops! Well, converting between languages is a daunting task. Nevertheless, in this case, the converter should have issued a to-do warning (as I see it usually does when it omits something). Unsigned...
  3. Replies
    7
    Views
    478

    Re: Convert C++ Code to Java

    I agree. The code the OP posted looks like written by a C++ newbie, which it probably is, considering where it originates (as someone's solution to a textbook exercise). No programming language...
  4. Re: use of algorithms in function cause ERROR: no instance of overloaded function

    Well, as they say on the moon: Switching to std::vector would be one small step for you but one giant leap for the quality of your code. :)
  5. Re: use of algorithms in function cause ERROR: no instance of overloaded function

    In the function case, the array sizes are unknown. I suggest you switch to std::vector (or std::array) rather than using old C-style arrays. It will work and is better C++.
  6. Replies
    7
    Views
    478

    Re: Convert C++ Code to Java

    Your assignment seems to come from here as someone's solution to an exercise in Absolute C++ by Savitch.
    ...
  7. Replies
    7
    Views
    401

    Re: how pass a class pointer to a object class?

    The immediate problem is that you declare a pointer variable in the constructor but never assign a pointer to it,



    Pixel *pix;


    And even if you did, the pointer will get lost when the...
  8. Replies
    1
    Views
    658

    Re: Java equals() selection

    If the null pointer has meaning and represents "nothing" or "empty" or something of that kind, I would use the Yoda condition. Otherwise, the null pointer is an error, and I would check for it...
  9. Re: Does functional programming replace GoF design patterns?

    If you accomplish a certain functionality according to the OO paradigm using OO patterns, you can achieve the same with the FP paradigm using FP patterns. So in this sense, it is true that FP...
  10. Re: Does functional programming replace GoF design patterns?

    You posted the same question here and got many high-rated replies,

    https://stackoverflow.com/questions/327955/does-functional-programming-replace-gof-design-patterns

    But it was 13 years ago, so...
  11. Thread: C++23

    by wolle
    Replies
    2
    Views
    2,116

    Sticky: How C++23 changes the way we write code

    These are links to the CppCon 2022 keynote speech, where Timur Doumler presents what he considers the four most important features of C++ 23, namely: deducing this, std::expected, std::mdspan, and...
  12. Replies
    1
    Views
    639

    Re: Inheterence issue

    You inherit the SummaryStrategy class into AverageSummary. It means AverageSummary is_a SummaryStrategy. But to be that, AverageSummary must implement all abstract methods of SummaryStrategy. Does it...
  13. Re: creation of simple tree like structure using stl vector c++, need help : )

    You could start from an implementation of a binary tree. There are plenty available on the internet and in textbooks.

    In the node declaration, replace the left and right child node pointers with a...
  14. Thread: Developers -

    by wolle
    Replies
    3
    Views
    610

    Re: Developers -

    The TIOBE index is a renowned indicator of the most popular languages right now,

    https://www.tiobe.com/tiobe-index/

    An advantage of TIOBE over one-off studies is that TIOBE also shows the...
  15. Replies
    4
    Views
    769

    Re: Manual programming question.

    You are welcome.

    The TROLL approach is a game changer, made possible by the recent discovery of the latent lines. A latent line knows its proper position in a text regardless of where you put it....
  16. Replies
    5
    Views
    764

    Re: Best book to learn Visual C++ from scratch?

    Visual C++ was once a free-standing product but has become part of Microsoft Visual Studio. There is a free community edition available,

    https://visualstudio.microsoft.com/downloads/

    Select...
  17. Replies
    4
    Views
    769

    Re: Manual programming question.

    You certainly could. In computer science, your approach is called The Robust Order of Latent Lines, or TROLL for short.
  18. Replies
    1
    Views
    768

    Re: Questions on what to study for the Software Development Program

    What is the nature of your admission? You provide a link to what seems to be an outsourcing company. Have you become a subcontractor to this company and now want to know what you need to study to...
  19. Thread: DWORD size in VS

    by wolle
    Replies
    6
    Views
    523

    Re: DWORD size in VS

    Maybe the variable is a DWORD array. In that case, the 5 you see could denote the array size (rather than the DWORD size.)
  20. Re: New with C programming, question about a loop situation

    You have not explained what is wrong, but your code effectively shifts the input integer five times to the right and then extracts the rightmost bit. For example, given input 32, which has a binary...
  21. Replies
    5
    Views
    2,264

    Re: Open source in Zürich

    Great, and chances are you meet people who like to get together and code in C++.

    Good luck!
  22. Replies
    5
    Views
    2,264

    Re: Open source in Zürich

    Most open source projects are online. However, in Zûrich, the ETH seems to organize in-person activities,

    https://gdsc.community.dev/eth-zurich/
  23. Replies
    2
    Views
    949

    Re: Deciding which language to pursue ...

    I suggest you look at Python, Java/C# (essentially equivalent), and C++. All are well-established and modern. All support procedural, object-oriented, and functional programming. And all are very...
  24. Replies
    6
    Views
    1,327

    Re: programming question

    Your best option probably is to team up with a good programmer. That is how many successful companies started - one with the vision and one with the know-how.
  25. Thread: stl find

    by wolle
    Replies
    12
    Views
    2,150

    Re: stl find

    Well, I should have tested my code but it was intended more as an illustration for a suggestion. Anyway, the GetValue function can be declared constexpr and noexcept to make it even better.
Results 1 to 25 of 713
Page 1 of 29 1 2 3 4





Click Here to Expand Forum to Full Width

Featured