Dozating machine controlled with step motor

Hello every1. I doing project for college presentation with Arduino. And problem is i’m unskilled with this programming language. My project is dozating machine controlled with step motor. And my program isnt working as i want to (because im noob with arduino) so i need help …

 const int ledPin1 = 13; // 25% 
const int ledPin2 = 12; // 50%
const int ledPin3 = 11; // 75%
const int ledPin4 = 10; // 100%
const int ledPin5 = 9;  // execute
const int switchPin11 =2;  // 1 concentrate (case1)
const int switchPin12 =3;  // + %
const int switchPin13 =4;  // - %
const int switchPin21 =5;  // 2 concentrate (case2)
const int switchPin22 =6;  // + %
const int switchPin23 =7;  // - %
const int switchPin31 =31; // 3 concentrate (case3)
const int switchPin32 =33; // + %
const int switchPin33 =35; // - %
int inc = 0; // +
int dec = 0; // -
int x = 0; // 1 pozit. x concentrate
int y = 0; // 2 pozit. y concentrate
int z = 0; // 3 pozit. z concentrate

void setup() {
pinMode(ledPin1, OUTPUT); 
pinMode(ledPin2, OUTPUT); 
pinMode(ledPin3, OUTPUT); 
pinMode(ledPin4, OUTPUT); 
pinMode(switchPin11, INPUT);
pinMode(switchPin12, INPUT);
pinMode(switchPin13, INPUT);
pinMode(switchPin21, INPUT);
pinMode(switchPin22, INPUT);
pinMode(switchPin23, INPUT);
  Serial.begin(9600);  
}

void loop() { 
dec = digitalRead(switchPin13);
inc = digitalRead(switchPin12);
if (inc == HIGH){
x = x + 1;
x <= 4;
}
if (dec == HIGH){
x = x - 1;
x >= 0;}
  Serial.println(x);
{
 if (x == 1) ;{
  digitalWrite(ledPin1, HIGH);
  digitalWrite(ledPin2, LOW);
  digitalWrite(ledPin3, LOW);
  digitalWrite(ledPin4, LOW);

}
 if (x == 2);{
  digitalWrite(ledPin1, HIGH);
  digitalWrite(ledPin2, HIGH);
  digitalWrite(ledPin3, LOW);
  digitalWrite(ledPin4, LOW);
}
 if (x == 3);{
  digitalWrite(ledPin1, HIGH);
  digitalWrite(ledPin2, HIGH);
  digitalWrite(ledPin3, HIGH);
  digitalWrite(ledPin4, LOW);
}
 if (x == 4) ;{
  digitalWrite(ledPin1, HIGH);
  digitalWrite(ledPin2, HIGH);
  digitalWrite(ledPin3, HIGH);
  digitalWrite(ledPin4, HIGH);
}
}
delay(250);
}

There is additional lanes in begining don’t mind them it’s for further programming.
So first problem is that when I monitor my X it goes like matrix numbers down.
Second problem don’t wkon why but arduino seems to ignore my commands x <= 4 and x >= 0 (ofc becoause i’m noob)
And final problem when my program starts all LEDs turn ON something isnt rifgt with command IF. P.S. sorry for bad english (3th language) and thx 4 those who is willing to help

if (x == 4) ;

Never do this.

    x <= 4;

I have no idea what that is meant to achieve.

that X can be less or equal 4 in shorter terms X can be only 0 1 2 3 4

 if (x == 4) ;

any suggestions to change it somehow?

x <= 4;

What if x is less than or equal to 4? This statement does nothing in either case.

x >= 0;

Nor does this.

{
 if (x == 1) ;

The curly brace is unnecessary. The ; is probably not what you want.

You question seemed to involve a stepper motor. Your code does not. Your code seems to involve LEDs. Which is it?

This is begginig of the project. Step motor will deliver concetrates but first of all I need to finish conntrol of dozating switchPins will control quantity. Sorryy my bad shouldnt involve in Topics name step motor :disappointed_relieved: