Don't see why this problem...
Just finding non-negative integer solution to a linear equation. No algorithm involved...\n\nThere are two linearly independent equations and two unknows, thus 
Just finding non-negative integer solution to a linear equation. No algorithm involved...\n\nThere are two linearly independent equations and two unknows, thus ensures unique solution. Namely, we have\n```\n4*J + 2*S = t,\n  J +   S = c.\n```\nThis gives \n```\nJ = t/2 - c,\nS = 2*c - t/2.\n```\n\n\n```\n    vector<int> numOfBurgers(int t, int c) {\n        if (t - 2*c < 0 || (t - 2*c) % 2 == 1 || 2*c - t/2 < 0) return {};\n        return {t/2 - c, 2*c - t/2};\n    }\n```
[]