public void check() {
		// Your solution here.
		int no_of_pixels = 0;
		SListNode current = image.getHead();
		if (current == null) {
			return;
		}
		SListNode nextcurrent = current.next;
		if (nextcurrent == null) {
			if (width * height != (int) current.runlength) {
				System.out.println("Errror!!!!!!!!!!");
			}
			return;
		}
		while (current.next != null) {
			if (nextcurrent.red == current.red
					&& nextcurrent.green == current.green
					&& nextcurrent.blue == current.blue) {
				System.out.println("Errror!!!!!!!!!!");
				break;
			}
			no_of_pixels += (int) current.runlength;
			current = nextcurrent;
			nextcurrent = nextcurrent.next;
		}
		if (width * height != no_of_pixels) {
			System.out.println("Errror!!!!!!!!!!");
		}
	}