fill method

void fill(
  1. int numberOfBytes,
  2. int value
)

Fills the next numberOfBytes with the given value

Implementation

void fill(int numberOfBytes, int value) {
  while (numberOfBytes > 0) {
    writeByte(value);
    numberOfBytes--;
  }
}