Advertisement
Guest User

Untitled

a guest
Jan 1st, 2016
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.44 KB | None | 0 0
  1. #include<cstdio>
  2. #include<algorithm>
  3. #include<cstdlib>
  4. #include<ctime>
  5.  
  6. using namespace std;
  7.  
  8. int number=100;
  9. int v[105];
  10. int memo[105][105];
  11. char songs[105][105]={"",
  12. "Ghost",
  13. "Shut Up + Dance",
  14. "Bad Blood",
  15. "Marvin Gaye",
  16. "Jealous",
  17. "All About That Bass",
  18. "Elastic Heart",
  19. "Shake It Off",
  20. "Lips Are Movin",
  21. "Tuesday",
  22. "Nasty Freestyle",
  23. "Heartbeat Song",
  24. "Bang Bang",
  25. "Love Me Like You Do",
  26. "Ex's & Oh's",
  27. "Photograph",
  28. "Back To Back",
  29. "Hey Mama",
  30. "You Know You Like It",
  31. "Don't",
  32. "Girl Crush",
  33. "Can't Feel My Face",
  34. "Blessings",
  35. "What Do You Mean?",
  36. "Thinking Out Loud",
  37. "El Perdon (Forgiveness)",
  38. "Classic Man",
  39. "The Hanging Tree",
  40. "She Knows",
  41. "Riptide",
  42. "Lean On",
  43. "Cheerleader",
  44. "GDFR",
  45. "Style",
  46. "Only",
  47. "House Party",
  48. "See You Again",
  49. "Cool For The Summer",
  50. "Sugar",
  51. "7/11",
  52. "Here",
  53. "Centuries",
  54. "FourFiveSeconds",
  55. "Waves",
  56. "Want To Want Me",
  57. "Honey, I'm Good.",
  58. "Lay Me Down",
  59. "Kick The Dust Up",
  60. "Hotline Bling",
  61. "Uptown Funk!",
  62. "Stitches",
  63. "Stay With Me",
  64. "Wildest Dreams",
  65. "Chains",
  66. "How Deep Is Your Love",
  67. "Hit The Quan",
  68. "Time of Our Lives",
  69. "The Hills",
  70. "Night Changes",
  71. "Talking Body",
  72. "Flex (Ooh Ooh Ooh)",
  73. "CoCo",
  74. "Like I'm Gonna Lose You",
  75. "Uma Thurman",
  76. "Habits (Stay High)",
  77. "I Don't Fuck With You",
  78. "Good For You",
  79. "Downtown",
  80. "My Way",
  81. "Budapest",
  82. "679",
  83. "Worth It",
  84. "I'm Not The Only One",
  85. "Ayo",
  86. "Chandelier",
  87. "Where Are U Now",
  88. "Drag Me Down",
  89. "Fight Song",
  90. "I Don't Mind (Usher)",
  91. "Dear Future Husband",
  92. "Locked Away",
  93. "Love Me Harder",
  94. "Take Your Time",
  95. "Renegades",
  96. "All Eyes On You",
  97. "Blank Space",
  98. "Watch Me",
  99. "Hello",
  100. "Animals",
  101. "Post To Be",
  102. "Earned It",
  103. "Truffle Butter",
  104. "Bitch Better Have My Money",
  105. "The Heart Wants What It Wants",
  106. "Take Me To Church",
  107. "Somebody",
  108. "Trap Queen",
  109. "Slow Motion",
  110. "One Last Time",
  111. "No Type",
  112. ""};
  113.  
  114. int compare(int a,int b)
  115. {
  116. if(memo[a][b]==-1)
  117. {
  118. printf("Is %s better than %s?\n",songs[a],songs[b]);
  119. int c;
  120. scanf("%d",&c);
  121. memo[a][b]=c;
  122. memo[b][a]=!c;
  123. if(c==1) return 1;
  124. return 0;
  125. }
  126. else return memo[a][b];
  127. }
  128.  
  129. int main()
  130. {
  131. for(int i=1;i<=number;i++)
  132. v[i]=i;
  133. for(int i=1;i<=number;i++)
  134. for(int j=1;j<=number;j++)
  135. memo[i][j]=-1;
  136. sort(v+1,v+number+1,compare);
  137. freopen("final.txt","w",stdout);
  138. for(int i=1;i<=number;i++)
  139. printf("%d. %s\n",i,songs[v[i]]);
  140. return 0;
  141. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement