1917: 支配值数目
Time Limit: 1 Sec Memory Limit: 64 MB Submit: 36 Solved: 23 [Submit][Status][Web Board]Description
Input
Output
Sample Input
5 5
1 3 5 7 9
2 3 4 7 8
Sample Output
12
#include<stdio.h> int main() { int m,n,i,j; int count=0; int a[1000],b[1000]; scanf("%d %d",&m,&n); for(i=0;i<m;i++) scanf("%d",&a[i]); for(j=0;j<n;j++) scanf("%d",&b[j]); for(i=0;i<m;i++) { for(j=0;j<n;j++) { if(a[i]>b[j]) count++; } } printf("%d",count); return 0; }