The stray character messages are because there are special characters in the code that the IDE cannot handle. This is often caused when code is copied from a Web page.
Here is a sanitised version that you can copy
void setup()
{
digitalWrite(13, LOW);
}
void loop()
{
pinMode(13, INPUT);
delay(1);
pinMode(13, OUTPUT);
delay(1);
}
but it still won't work
The pinMode() needs to go only in setup() to set the mode to set pin 13 to OUTPUT
Replace the pinMode()s in loop() with digitalWrite()s to change the state of the LED
Increase the delay() times to 1000 and experiment later with different values.