Hi, can someone help me plz. i don't know why it's not working

// fluxo de pessoas 2021
//

int Unid = 0;
int Dec = 0;

//configuracoes dos pinos do arduino

void setup()
{
pinMode (2, OUTPUT);
pinMode (3, OUTPUT);
pinMode (4, OUTPUT);
pinMode (5, OUTPUT);
pinMode (6, OUTPUT);
pinMode (7, OUTPUT);
pinMode (8, OUTPUT);
pinMode (9, OUTPUT);
pinMode (10, INPUT);
pinMode (11, INPUT);
pinMode (12, INPUT);
Serial.println(Unid);

}

//Programa principal
void loop()
{
Serial.begin(9600); // observar a variavel Unid
if (digitalRead (10) == HIGH)// sensor PIR 1
{
delay (1000); // Wait for 1 second
}
if (digitalRead (11) == HIGH)
{
Unid++;
if (Unid == 10)
{
Unid= 0;
Dec++;
if (Dec == 10)
{
Dec=0;
}
}
}

//if (digitalRead (11) == HIGH)
//{
// delay (1000); // Wait for 1 second
// Unid --;
// if (Unid == -1)
// {
// Unid=9;
// Dec--;
// if (Dec == -1)
// {
// Dec=0;
// }
// }
// }

switch (Unid)
{
case 0:
//ZERO (0000)
digitalWrite (3, LOW);
digitalWrite (4, LOW);
digitalWrite (5, LOW);
digitalWrite (2, LOW);
break;

case 1: 
//UM (0001)
digitalWrite (3, LOW);
digitalWrite (4, LOW);
digitalWrite (5, LOW);
digitalWrite (2, HIGH);
break;

case 2:
//DOIS (0002)
digitalWrite (3, LOW);
digitalWrite (4, LOW);
digitalWrite (5, HIGH);
digitalWrite (2, LOW);
break;

case 3:
//TRES (0003)
digitalWrite (3, LOW);
digitalWrite (4, LOW);
digitalWrite (5, HIGH);
digitalWrite (2, HIGH);
break;

case 4:
//QUATRO (0004)
digitalWrite (3, LOW);
digitalWrite (4, HIGH);
digitalWrite (5, LOW);
digitalWrite (2, LOW);
break;

case 5:
//CINCO(0005)
digitalWrite (3, LOW);
digitalWrite (4, HIGH);
digitalWrite (5, LOW);
digitalWrite (2, HIGH);
break;

case 6:
//SEIS (0006)
digitalWrite (3, LOW);
digitalWrite (4, HIGH);
digitalWrite (5, HIGH);
digitalWrite (2, LOW);
break;

case 7:
//SETE (0007)
digitalWrite (3, LOW);
digitalWrite (4, HIGH);
digitalWrite (5, HIGH);
digitalWrite (2, HIGH);
break;

case 8:
//OITO (0008)
digitalWrite (3, HIGH);
digitalWrite (4, LOW);
digitalWrite (5, LOW);
digitalWrite (2, LOW);
break;

case 9:
//NOVE (0009)
digitalWrite (3, HIGH);
digitalWrite (4, LOW);
digitalWrite (5, LOW);
digitalWrite (2, HIGH);
break; 

}

switch (Dec)
{
case 0:
//ZERO (0000)
digitalWrite (7, LOW);
digitalWrite (8, LOW);
digitalWrite (9, LOW);
digitalWrite (6, LOW);
break;

case 1:
//UM (0001)
digitalWrite (7, LOW);
digitalWrite (8, LOW);
digitalWrite (9, LOW);
digitalWrite (6, HIGH);
break

 ;case 2:
//DOIS (0002)
digitalWrite (7, LOW);
digitalWrite (8, LOW);
digitalWrite (9, HIGH);
digitalWrite (6, LOW);
break;

 case 3:
//TRES (0003)
digitalWrite (7, LOW);
digitalWrite (8, LOW);
digitalWrite (9, HIGH);
digitalWrite (6, HIGH);
break;

 case 4:
//QUATRO (0004)
digitalWrite (7, LOW);
digitalWrite (8, HIGH);
digitalWrite (9, LOW);
digitalWrite (6, LOW);
break;

 case 5:
//CINCO (0005)
digitalWrite (7, LOW);
digitalWrite (8, HIGH);
digitalWrite (9, LOW);
digitalWrite (6, HIGH);
break;

 case 6:
//SEIS (0006)
digitalWrite (7, LOW);
digitalWrite (8, HIGH);
digitalWrite (9, HIGH);
digitalWrite (6, LOW);
break;

 case 7:
//SETE (0007)
digitalWrite (7, LOW);
digitalWrite (8, HIGH);
digitalWrite (9, HIGH);
digitalWrite (6, HIGH);
break;

 case 8:
//OITO (0008)
digitalWrite (7, HIGH);
digitalWrite (8, LOW);
digitalWrite (9, LOW);
digitalWrite (6, LOW);
break;

 case 9:
//NOVE (0009)
digitalWrite (7, HIGH);
digitalWrite (8, LOW);
digitalWrite (9, LOW);
digitalWrite (6, HIGH);
break;

}

delay (200); // Wait for 100 millisecond(s)
goto main;
}

You'll have explain what "not working" means.

Uh-oh.

Please remember to use code tags when posting code

Something very important has to go before this.

sorry bruh its my first time using this forum, and i don't know what is wrong too

and what it would be?

You only need to do this once, move it into the setup( ) function.

Serial.begin(9600); // observar a variavel Unid


How are your switches wired ?


In the Arduino IDE, use Ctrl T or CMD T to format your code then copy the complete sketch.

Use the </> icon from the ‘reply menu’ to attach the copied sketch.

When you want help with something "not working" you need to tell us what it is supposed to do, if it does anything at all and what it does that isn't what you wanted.

Steve

First step is getting it to compile.