refactorise code and extract default numbers
resolved conflicts