/* adv03.c: Adv350 - copyright Crowther and Woods 2020. Licensed under
 * GPL (version 3 or later) or the Modified BSD Licence, whichever
 * is asserted by the supplied LICENCE file.*/

#include "adv0.h"
#include "adv3.h"
int p1()
{
   if (p2() || loop) return 0;
   if (p3() || loop) return 0;
   return 1;
}
int p4()
{
#if ADVLIB
   rep = 0;
   if (nrep < 1) { if (p5() || loop) return 0; rep = 1; }
   if (nrep < 2) { if (p6() || loop) return 0; rep = 2; }
   if (nrep < 3) { if (p7() || loop) return 0; rep = 3; }
   if (nrep < 4) { if (p8() || loop) return 0; rep = 4; }
#else
   if (p5() || loop) return 0;
   if (p6() || loop) return 0;
   if (p7() || loop) return 0;
   if (p8() || loop) return 0;
#endif /* ADVLIB */
   return 1;
}
int p27()
{
   if (p28() || loop) return 0;
   if (p29() || loop) return 0;
   if (p30() || loop) return 0;
   return 1;
}
int p0(void)
{return 0;}
