Run-length encoding (RLE) technique simulation or implementation in java programming language with example