fork(1) download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. int n;
  6. cin >> n;
  7. int st = 0, vt = 0;
  8. for (int i = 0; i < n; i++) {
  9. int s, v;
  10. cin >> s >> v;
  11. st+= s;
  12. vt+= v;
  13. }
  14. if (st > vt){
  15. cout << "S" << endl;
  16. }
  17. else if (st < vt){
  18. cout << "V" << endl;
  19. }
  20. else if (vt==st){
  21. cout << "DRAW" << endl;
  22. }
  23. return 0;
  24. }
  25.  
Success #stdin #stdout 0.01s 5320KB
stdin
1
1 12
stdout
V