Java

#018 [질문] 순서가 달라질 시 오류나는 코드

Ahn_Bo 2020. 12. 7. 09:10
// 순서가 달라질 시, 오류나는 이유
String[] commandBits = command.split(" ");

if ( commandBits.length <= 2) {

System.out.println("게시물 번호를 입력해주세요.");

continue;

}


int inputedId = integer.parselnt(commandBites) →

→ 결론은 만약 고객이 잘못 입력했을 때를 대비하여 추가 코드 입력할 것

 

 

 

*전체적인 일상은 노션을 통해 작성하고 있습니다.

링크 : www.notion.so/006-6103e7dbfbbd4678963ab63ed59b4ad0