int 変数 = 0;
do{
  if(変数 != 0) printf("0〜100違う");
  scanf("%d",&変数);
 } while (変数 < 0 || 変数 > 100);

みたいな感じのやつどういう仕組み?