• .NET - OOD / OOP - Programming

    Priority Queue in .NET 6

    Priority Queue is a data structure in computer science that is used to manage a collection of prioritized elements. It allows adding, removing and peeking (reading) elements in the order of their priority. The priority queue is used in many applications such as job scheduling, network routing, data compression, and…

  • .NET - OOD / OOP - Programming

    Custom comparer of a SortedSet

    Sorting collections is a common task in programming, and .NET provides a variety of tools to do so efficiently. One such tool is the SortedSet class, which represents a collection of unique elements sorted in ascending or descending order. By default, SortedSet uses the default comparer for its type, but…

  • OOD / OOP

    Returning buffers with C++ and Boost

    In the article comparing CPU and GPU implementations of the median filter, the class was designed to receive image buffers with the AddSample method and return a pointer to the image buffer with the GetMedianImage method: class TM_CPURefImpl : public TM_BaseClass { public: TM_CPURefImpl(const int _NumSamples, const int _BufferSize); virtual…

  • OOD / OOP

    An object-oriented approach to FizzBuzz

    FizzBuzz is described as: Write a program that prints the integers from 1 to 100. But for multiples of three print “Fizz” instead of the number and for the multiples of five print “Buzz”. For numbers which are multiples of both three and five print “FizzBuzz” It takes a couple…