R/GCDR.R

Defines functions number_func

Documented in number_func

#' calculate GCD
#'
#'This function calculate the greatest common denominator
#'
#'@examples
#'
#'number_func(5,9)

number_func <- function(a,b){
  while(b != 0){
    count <-a %% b
    a <- b
    b <- count
  }
  return(a)
}
21810669/GCD documentation built on May 25, 2020, 12:43 a.m.