Why does my program crash sometimes?

Hello,

Related topic:

Where did you get the error? These may be highlighted when found as in example below.

I am seeing this error with your code:

Example:

// String s; // s is not initialized and is a null
String s = ""; // s is initialized and not a null

void setup()
  {
  text(s, 0, 0);
  }

Please format your code as a courtesy to our community:
https://discourse.processing.org/faq#format-your-code

:)