Pls i need help on this project

If I fail this project, I have to repeat the year. Please Help. I am making a distance detector using an Arduino, a HC-SRO4 Ultrasonic Sensor, a Buzzer, and some LED’s. The ultimate goal of this project is to use the buzzer and LED’s to display how far the object is from the ultrasonic sensor. Here is my code:
#define trigPin 7
#define echoPin 6
#define led 13
#define led2 12
#define led3 11
#define led4 10
#define led5 9
#define led6 8
#define buzzer 3
#define motor 4
int sound = 250;

void setup() {
// put your setup code here, to run once:

Serial.begin (9600);
pinMode(echoPin, INPUT);
pinMode(trigPin, OUTPUT);
pinMode(led, OUTPUT);
pinMode(led2, OUTPUT);
pinMode(led3, OUTPUT);
pinMode(led4, OUTPUT);
pinMode(led5, OUTPUT);
pinMode(led6, OUTPUT);
pinMode(buzzer, OUTPUT);
pinMode(motor, OUTPUT);

}

void loop() {
// put your main code here, to run repeatedly:
long duration, distance;
digitalWrite(trigPin, LOW);
delayMicroseconds(2);
digitalWrite(trigPin, HIGH);
delayMicroseconds(10);
digitalWrite(trigPin, LOW);
duration = pulseIn(echoPin, HIGH);
distance = (duration/2) / 29.1;

if (distance <= 50)
{
digitalWrite(led, HIGH);
sound = 250;
digitalWrite(motor, HIGH);
delayMicroseconds(30);
digitalWrite(motor, LOW);
}
else {
digitalWrite(led,LOW);
digitalWrite(motor, LOW);
}
if (distance < 35) {
digitalWrite(led2, HIGH);
sound = 260;
digitalWrite(motor, HIGH);
delayMicroseconds(25);
digitalWrite(motor, LOW);
}
else {
digitalWrite(led2, LOW);
digitalWrite(motor, LOW);
}
if (distance < 20) {
digitalWrite(led3, HIGH);
sound = 270;
digitalWrite(motor, HIGH);
delayMicroseconds(20);
digitalWrite(motor, LOW);
}
else {
digitalWrite(led3, LOW);
digitalWrite(motor, LOW);
}
if (distance < 15) {
digitalWrite(led4, HIGH);
sound = 280;
digitalWrite(motor, HIGH);
delayMicroseconds(15);
digitalWrite(motor, LOW);
}
else {
digitalWrite(led4,LOW);
digitalWrite(motor, LOW);
}
if (distance < 10) {
digitalWrite(led5, HIGH);
sound = 290;
digitalWrite(motor, HIGH);
delayMicroseconds(10);
digitalWrite(motor, LOW);
}
else {
digitalWrite(led5,LOW);
digitalWrite(motor, LOW);
}
if (distance < 5) {
digitalWrite(led6, HIGH);
sound = 300;
digitalWrite(motor, HIGH);
delayMicroseconds(5);
digitalWrite(motor, LOW);
}
else {
digitalWrite(led6,LOW);
digitalWrite(motor, LOW);
}

if (distance > 50 || distance <= 0){
Serial.println(“Out of range”);
noTone(buzzer);
}
else {
Serial.print(distance);
Serial.println(" cm");
tone(buzzer, sound);

}
delay(500);
}

The problem is, the LEDs and buzzer sounds off when nothing is in front of it. The LEDs are supposed to progressively turn on the closer you get, the same is supposed to be true for how loud the buzzer is.