Count of Maximum - CodeChef
Simplify:

        count[x] = ++count[x];

        // Why not just;
        ++count[x];


Variable name length:

for (auto i = 0; i &lt; test_cases; ++i) {


Have you ever tried searching for all occurrences of the variable i in the resulting loop. The number of false positives will be a pain in the arse. Name your loop variables so you can find them easily.

Hiding variables names:

    for (std::size_t i = 0; i &lt; size; ++i) {


Though not technically illegal. This becomes a maintenance problem. It's OK for you today as you just wrote the code. But for anybody else (or you in years time) this is can be a pain. Try and give your variables unique meaningful names (self documenting code is a brilliant practice but it requires variable names to be meaningful).

The whole loop where you search for the largest repeat:

    for (std::size_t i = 0; i &lt; size; ++i) {


This can be done inline while you were counting. I would not have a second loop to work it out after the fact.

I would simplify this condition:

} else if (i.second == numberCount) {
            if (i.first &lt; number) {

// I find it easier to read as:

} else if (i.second == numberCount) &amp;&amp; (i.first &lt; number) {


This seems a bit redundant:

        } else {
            continue;
        }


Personally I think initializing integers with {} looks terrible (and is slightly confusing).

std::size_t size{};

std::size_t size = 0;  // Much easier to read.


Whats the point in initizliaing a variable just before you write over it?

    std::size_t size{};   // Why initialize it here
    std::cin &gt;&gt; size;     // Only to trash the initialization here.


Address Comments:

    int number{};
    int numberCount{};
    for (std::size_t i = 0; i &lt; size; ++i) {

        std::cin &gt;&gt; x;
        std::size_t&amp;  countV = count[x];

        ++countV;

        if (countV &gt; numberCount || (countV == numberCount &amp;&amp; x &lt; number))
        {
            number      = x;
            numberCount = countV;
        }
    }