Need help for SPOJ Problem: Fun with Sequences

#include<stdio.h>
int main()
{ int n,m,i,j;
int s[101],q[101];
scanf("%d",&n);
for(i=0;i<n;i++)
scanf("%d",&s[i]);
scanf("%d",&m);
for(i=0;i<m;i++)
scanf("%d",&q[i]);

  for(i=0,j=0;i<n;)
  {
  if(s[i]-q[j]<0)
  {
  printf("%d ",s[i]);
  i++;

  }
  else if(s[i]==q[j])
  i++;
  else
  j++;
  
  }

 return 0;
}

@vjmanit >> your code doesn’t print elements in S that are greater than all elements in Q.

Example test cases where your code fails:

2
1 2
2
-1 -2

3
-3 1 2
2
-1 -2

here is a link to the modified code which is accepted on spoj > ideone

//