variable "RR" replaced by "numberOfRow"