Help !!

Revision en1, by Saul_Goodman_, 2022-01-26 20:16:33

In this problem: https://codeforces.com/contest/1608/problem/C I keep getting WA and I don't know exactly what is wrong with my code

Approach: I make 2 arrays that represent the value of A and the value of B and then sort them according to the value in ascending order. After that, I go through the array A from the end till the beginning and for each i I see if it can beat the biggest A in the second map which is B, and if this is true then this i can win the game. after I finish with array A I do the same thing with array B.

Code: https://ideone.com/txcuRy

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en1 English Saul_Goodman_ 2022-01-26 20:16:33 575 Initial revision (published)