You're given a number $$$n$$$ It may be prime or not, It's required from you to get 4 positive prime numbers at which their summition equals to $$$n$$$, and if this isn't possible, then state that (There's more that one test cast BTW).
My approach was to get all prime numbers form 2 to 10000000 using sieve theory only once, and to try assume 3 of these numbers and get every possible combination of 2's and 3's (Assuming that all prime numbers can be deduce from summition of these two) let these numbers are $$$x$$$, $$$y$$$ and $$$z$$$ and if there exist a fourth number at which this 4th number = n - x + y + z
and If it's positive and prime, then we found the answer otherwise this won't be possible.
If there's something wrong with my approach? If not there's the mistake in my code Link to the problem is here