Is it worth creating another method to simplify methods that repeat themselves?

前端 未结 0 969
天涯浪人
天涯浪人 2020-12-03 10:53

I have several public methods in my code which are all the same :

public boolean modifyLastName(int nth, String lastName) {

    if (!isNthValid(nth)) {
              


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题