expected constructor, destructor, or type conversion before '(' token

when i try to upload this code i get this error message:

Arduino: 1.8.8 (Windows 10), Board: "Arduino/Genuino Uno"

magic_8_ball:4:8: error: expected constructor, destructor, or type conversion before '(' token

pinMode(8, INPUT);

^

C:\Users\105195005\Documents\magic_8_ball\magic_8_ball.ino: In function 'void setup()':

magic_8_ball:22:1: error: expected ';' before '}' token

}

^

exit status 1
expected constructor, destructor, or type conversion before '(' token

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.

magic_8_ball.ino (2.13 KB)

Please follow the advice on posting a programming question given in Read this before posting a programming question

In particular note the advice to Auto format code in the IDE and to use code tags when posting code here as it prevents some combinations of characters in code being interpreted as HTML commands such as italics, bold or a smiley character, all of which render the code useless

The following line of code is outside of a function:

pinMode(8, INPUT);

C/C++ forbid any statements at top level, there's only declarations. Calling the function pinMode() is
not a declaration (in C++ terms...).

The place for all such setup is setup().

OP's code

int Rand;
pinMode(8, INPUT);
#include <Wire.h>
#include <LiquidCrystal_I2C.h>
 LiquidCrystal_I2C lcd(0x27, 2, 1, 0, 4, 5, 6, 7, 3, POSITIVE);

 
 void setup() {
  Serial.begin(9600);
  lcd.begin(16,2);
  for(int i = 0; i< 3; i++)
 {
 lcd.backlight();
 delay(250);
 lcd.noBacklight();
 delay(250);
 }
 lcd.backlight();
 Rand = 0
}

void loop() {
  if (digitalRead(8) == HIGH);
  {
    Rand = random(1,21);
  }
  lcd.clear();
  if (Rand == 1);
  {
    lcd.setCursor(1,0);
    lcd.print("AS I see it, yes");
  }
  if (Rand == 2);
  {
    lcd.setCursor(1,0);
    lcd.print("Ask again later");
  }
  if (Rand == 3);
  {
    lcd.setCursor(1,0);
    lcd.print("Not really sure");
  }
  if (Rand == 4);
  {
    lcd.setCursor(1,0);
    lcd.print("I wont tell you");
  }
  if (Rand == 5);
  {
    lcd.setCursor(1,0);
    lcd.print("Ask again");
  }
  if (Rand == 6);
  {
    lcd.setCursor(1,0);
    lcd.print("Not really");
  }
  if (Rand == 7);
  {
    lcd.setCursor(1,0);
    lcd.print("It is certain");
  }
  if (Rand == 8);
  {
    lcd.setCursor(1,0);
    lcd.print("It is so");
  }
  if (Rand == 9);
  {
    lcd.setCursor(1,0);
    lcd.print("");
  }
  if (Rand == 10);
  {
    lcd.setCursor(1,0);
    lcd.print("My reply is no");
  }
  if (Rand == 11);
  {
    lcd.setCursor(1,0);
    lcd.print("Sources say no");
  }
  if (Rand == 12);
  {
    lcd.setCursor(1,0);
    lcd.print("Not looking good");
  }
  if (Rand == 13);
  {
    lcd.setCursor(1,0);
    lcd.print("Outlook, good");
  }
  if (Rand == 14);
  {
    lcd.setCursor(1,0);
    lcd.print("Hazy, try again");
  }
  if (Rand == 15);
  {
    lcd.setCursor(1,0);
    lcd.print("I think so");
  }
  if (Rand == 16);
  {
    lcd.setCursor(1,0);
    lcd.print("Very doubtful");
  }
  if (Rand == 17);
  {
    lcd.setCursor(1,0);
    lcd.print("Without a doubt");
  }
  if (Rand == 18);
  {
    lcd.setCursor(1,0);
    lcd.print("Yes");
  }
  if (Rand == 19);
  {
    lcd.setCursor(1,0);
    lcd.print("Definitely");
  }
  if (Rand == 20);
  {
    lcd.setCursor(1,0);
    lcd.print("Rely on it");
  }
}
Rand = 0

needs a semi-colon on the end

but all your if statements that look like

if (Rand == 1);
{
...
}

need the semi-colons removing.
The semi-colon terminates the if statement and the code between the following braces is always executed.