Advertisement
Guest User

Untitled

a guest
Jan 23rd, 2017
110
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.39 KB | None | 0 0
  1. #include<stdio.h>
  2.  
  3. void main()
  4.  
  5. {
  6.  
  7. int num[7]={0,}, i, k, j,temp;
  8.  
  9.  
  10.  
  11. for(i=1; i<7; i++) scanf("%d", &num[i]);
  12.  
  13. for (j = 1; j < 6; j++){
  14.  
  15. for (k = j + 1; k < 7; k++){
  16.  
  17. if (num[j] > num[k]){
  18.  
  19. temp = num[j];
  20.  
  21. num[j] = num[k];
  22.  
  23. num[k] = temp;
  24.  
  25. }
  26.  
  27. }
  28.  
  29. }
  30.  
  31. if(num[1]&&num[2]&&num[3])
  32.  
  33. {
  34.  
  35. if(num[4]&&num[5]&&num[6])
  36.  
  37. printf("gin");
  38.  
  39. }
  40.  
  41. else printf("lose");
  42.  
  43.  
  44.  
  45.  
  46.  
  47. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement