0
/**
* return the index of the Predator with the given name. Case does not matter.
* No External Classes Permitted to Be Used in This Method Apart from
* String.Equals and String.ToUpperCase
* My Solution Length in Lines (note yours can be longer or shorter): 4
*
* @param name the name of the Predator to be found
* @return the position of the searched for Predator. -1 if none found
*/
public int indexOf(String name) {
}
내가해야 할 일을 알고 있지만 해결 방법을 모르겠습니다. 그래서 내가 배열을 통해 반복해야하고 이름이 해당 요소의 이름과 같으면 INDEX (위치)를 반환하는지 확인해야합니다. 누군가 제발 도와 줄 수 있니?indexOf (문자열 이름) 메소드에 문제가 있습니다. Java
정확히 무엇을하고 싶습니까? –
문자열 배열이 있습니까? –
plz 코드 달성에 도움을 주시고 코드에서 직면 한 문제에 대해 좀더 구체적으로 말씀 해주십시오 – mhasan