Skip to content

Conversation

@junghongseop
Copy link
Member

@junghongseop junghongseop commented Jun 26, 2023

이밤돌학생의 원서 재제출, 원서 조회, 불합 여부, 학생이 자신의 원서
조회하는 기능을 구현했다.`

1. 구현 여부

요구사항 구현 여부 *

  • 학생은 원서를 제출할 수 있습니다.
  • 학교는 받은 원서를 점수 순으로 다음 정보를 확인할 수 있습니다.
    • 지원자의 이름, 전화번호, 출신 중학교
    • 지원자의 성적, 출결, 가산점
  • 학생은 자신이 제출한 원서의 상태를 확인할 수 있습니다.

제한 사항 구현 여부 *

  • 원서는 한 번만 제출할 수 있습니다.

테스트

  • (진행한 테스트 케이스를 모두 적어주세요)

2. 진행 중 느낀점

과제를 진행하며 한 고민들 *

  • 친구들과 프로젝트를 하기 위해서 3월부터 자바를 배웠지만 3개월이 지난 지금도 자바 코드를 짜는 게 많이 어렵고 과연 백엔드에 제 적성이 맞는지, 동아리에 들어가도 선배들이 주시는 과제를 수행할 수 있을지 많은 고민을 했습니다.

발생한 이슈와 해결 방법

  • 자바를 배우긴 했지만 머릿속에 어떻게 코드를 짜면 좋을지만 생각이 나고 막상 코드를 짜려고 하다 보니 힘이 들어지만 처음에는 구글링을 통해 자바 문법을 찾아 보았고 구글링을 하더라도 찾기 어려웠다면 주변에 자바를 할 줄 아는 친구에게 물어봐 문제를 해결 해 나갔습니다.

질문

  • 자바를 배우기는 했지만 코드를 짜는데 있어 많이 미숙한데 만약 동아리에 들어가면 자바를 조금 더 공부하는데 시간을 주시나요?

이밤돌학생의 원서 재제출, 원서 조회, 불합 여부, 학생이 자신의 원서
조회하는 기능을 구현했다.`
@junghongseop junghongseop requested a review from a team as a code owner June 26, 2023 11:19
@gimhanul
Copy link
Member

@junghongseop

제목 형식 "[이름] 과제 제출합니다"로 통일해주세요
그리고, 완료한 사항에 체크박스 표시해주세요!

@junghongseop junghongseop changed the title ADD::code complete [정홍섭]ADD::code complete Jun 26, 2023
@junghongseop junghongseop changed the title [정홍섭]ADD::code complete [정홍섭]과제 제출합니다 Jun 26, 2023
@gimhanul
Copy link
Member

🙌 @junghongseop 님 안녕하세요

밤돌이로 백엔드 개발 팀입니다.

먼저, 과제 전형 기간 동안 수고하셨습니다!
과제를 수행하시면서 많이 배우셨길 바랍니다.

과제를 준비하면서 얻어가셨길 바랐던 것은

1. 자기주도적으로 공부하기
2. 객체지향적으로 설계하기
3. 깃허브 사용법 익히기

인데요, 다들 어느정도 얻어가신 것 같아 뿌듯하네요.

과제 전형 점수 안내드립니다.

자세한 감점 사유가 궁금하면 따로 연락주세요.

코드 가독성 실행 학구열 성실성 테스트 총점
28 28 30 7 0 93

총점 93점으로, 1차 과제 전형에서 합격하셨습니다.
오늘 안으로 면접 일정을 잡아 개인적으로 연락드리겠습니다!

감사합니다.

Copy link
Member

@gimhanul gimhanul left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

수고하셨습니다~
리뷰 참고해서 반영하셔도 되고, 그대로 머지하셔도 됩니다!

this.attendance = attendance;
this.plusScore = plusScore;
this.total = score + attendance + plusScore ; //합불을 구하는 기준
// System.out.println(total);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
// System.out.println(total);

사용하지 않아서 주석처리 해 놓은 것들은 삭제해주는 게 좋아요

Comment on lines +49 to +51
public void setPass(boolean pass){
this.pass = pass;
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

이런 메서드는 setter를 사용하기보다는
pass()failed() 메서드로 만들어서 사용하는 게 더 읽기 쉬워질 것 같아요
덧붙이면 setter를 지양해야 하기도 하구요.
관련된 내용은 검색해서 찾아보시면 좋을 것 같아요!

Comment on lines +56 to +62
if (document.total < total){
return 1; //document.total < total은 현재 객체인 total값이 더 크다는 것을 의미
} //따라서 현재객체가 document 객체보다 우선순위가 높다는 것을 나타내기 위해 1을 반환
else if (document.total > total){
return -1; //document.total > total은 현재 객체의 total 값이 더 작다는 것을 의미
} // 현재 객체가 document 객체보다 우선순위가 낮다는 것을 나타내기 위해 -1을 반환
return 0; //두 조건에 해당하지 않을 경우, total 값이 동일하다는 것을 의미, 두 객체의 우선순위가 같다는 것을 나타내기 위해 0을 반환
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
if (document.total < total){
return 1; //document.total < total은 현재 객체인 total값이 더 크다는 것을 의미
} //따라서 현재객체가 document 객체보다 우선순위가 높다는 것을 나타내기 위해 1을 반환
else if (document.total > total){
return -1; //document.total > total은 현재 객체의 total 값이 더 작다는 것을 의미
} // 현재 객체가 document 객체보다 우선순위가 낮다는 것을 나타내기 위해 -1을 반환
return 0; //두 조건에 해당하지 않을 경우, total 값이 동일하다는 것을 의미, 두 객체의 우선순위가 같다는 것을 나타내기 위해 0을 반환
return total - document.total;

이렇게 짧게 줄일 수 있어요.
그리고 줄여서 짧아진 메서드는 람다식으로도 표현할 수 있을 것 같네요
관련된 내용은 람다 키워드로 검색해보세용

// TODO-1 이밤돌 학생 원서
// 이밤돌 학생이 부산소프트웨어마이스터고등학교에 낼 원서를 작성합니다.

bamdol.writeDocument("010-1234-5678", 100, 50, 5); // score 만점: 100, attendance 만점: 50, plusScore 만점: 5
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

만점이 몇 점인지 나타내는 주석은 여기보다는 Document 클래스로 옮기는 게 좋겠네요

Comment on lines +8 to +10
Student bamdol = new Student("이밤돌", "밤돌중학교");
// 곰돌중학교를 다니고 있는 금곰돌 학생을 생성합니다.

Student gomdol = new Student("금곰돌", "곰돌중학교");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

중학교를 생성할 때 물론 쓸모는 없겠지만 만들어둔 school 클래스를 넣는 것도 좋았을 것 같아요.
필요하진 않아도 "학교"라는 의미가 더 잘 드러나니까요

private String name;
private String middleSchool;
private Document document = new Document();
private int count = 1;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

이런 변수는 그냥 count로 두기보다는
제출횟수 같은 네이밍을 사용하는 게 의미가 더 잘 드러나요


/*학생 원서 재체출*/
public void sentDocument(School school){
if(count > 0){ //count > 0은 학생이 원서를 아직 제출하지 않았을 경우를 나타냄. 즉, count변수가 1보다 큰 경우
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

count를 사용하는 것 보다 boolean을 사용하는 게 더 좋겠네요
어차피 제출은 한 번만 할 수 있으니 제출함/안함 두 개의 상태만 있으니까요

Comment on lines +13 to +14
public void getDocument(Document document){
documents.add(document);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

메서드 이름과 메서드가 하고 있는 역할이 정반대인 것 같아요

@gimhanul gimhanul changed the base branch from main to hongsub June 29, 2023 23:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants