Guest User

Untitled

a guest
May 21st, 2018
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.49 KB | None | 0 0
  1. void must_see_movie(char movies [][100],char movies_info[9][10],unsigned int num [3])
  2. {
  3. int rank[10] = {0};
  4. int i,j,h;
  5. char * cretrion , * p = &movies[0][0],* check;
  6.  
  7.  
  8. for(i=0;(*p >= 0 && *p <= 127);i++)
  9. {
  10. p = &movies[i][0];
  11. for(h=0;h<3;h++)
  12. {
  13. cretrion = &movies_info[num[h]][0];
  14. check = strstr(*p,*cretrion);
  15. if(check != NULL)
  16. rank[i]++;
  17. }
  18. }
  19.  
  20. for(j=0;j<=i;j++)
  21. printf("%d",rank[j]);
  22.  
  23.  
  24. }
Add Comment
Please, Sign In to add comment