묻고 답해요
158만명의 커뮤니티!! 함께 토론해봐요.
인프런 TOP Writers
-
미해결스프링 프레임워크는 내 손에 [스프2탄]
com.mysql
43강 4분 <dependency><groupId>com.mysql</groupId><artifactId>mysql-connector-j</artifactId> </dependency> 저는 이부분에 처음부터 이렇게 뜨는데 왜그런걸까요?
-
미해결스프링 핵심 원리 - 기본편
DiscountPolicy를 호출할 때 왜 인터페이스를 호출하나요?
학습하는 분들께 도움이 되고, 더 좋은 답변을 드릴 수 있도록 질문전에 다음을 꼭 확인해주세요.1. 강의 내용과 관련된 질문을 남겨주세요.2. 인프런의 질문 게시판과 자주 하는 질문(링크)을 먼저 확인해주세요.(자주 하는 질문 링크: https://bit.ly/3fX6ygx)3. 질문 잘하기 메뉴얼(링크)을 먼저 읽어주세요.(질문 잘하기 메뉴얼 링크: https://bit.ly/2UfeqCG)질문 시에는 위 내용은 삭제하고 다음 내용을 남겨주세요.=========================================[질문 템플릿]1. 강의 내용과 관련된 질문인가요? (예/아니오)2. 인프런의 질문 게시판과 자주 하는 질문에 없는 내용인가요? (예/아니오)3. 질문 잘하기 메뉴얼을 읽어보셨나요? (예/아니오)[질문 내용] RateDIscountPolicy로만 불러오는게 아니라 왜private final DiscountPolicy discountPolicy = new FixDiscountPolicy(); 처럼 인터페이스로부터 불러 오나요?인터페이스는 구현체를 만들때에만 쓰이는게 아닌가요?
-
해결됨Slack 클론 코딩[백엔드 with NestJS + TypeORM]
try문 밖에서 에러 발생시 트랜잭션이 release가 안됩니다.
12:00 시작된 join 매서드를 만들고 실행을 시켜보니 에러 처리를 하면 커넥션 pool이 종료되지 않는거 같습니다. 이메일이 중복된 user를 insert하려 할 때 new ForbiddenException이 실행이 됩니다. 하지만 finally문이 실행이 안되는거 같습니다.async join(email: string, nickname: string, password: string) { const queryRunner = this.dataSource.createQueryRunner(); await queryRunner.connect(); await queryRunner.startTransaction(); const user = await queryRunner.manager .getRepository(Users) .findOne({ where: { email } }); if (user) { throw new ForbiddenException('이미 존재하는 사용자입니다'); } const hashedPassword = await bcrypt.hash(password, 12); try { const returned = await queryRunner.manager.getRepository(Users).save({ email, nickname, password: hashedPassword, }); const workspaceMember = queryRunner.manager .getRepository(WorkspaceMembers) .create(); workspaceMember.User = returned.id; workspaceMember.Workspace = 1; // throw new NotFoundException('롤백해봐'); await queryRunner.manager .getRepository(WorkspaceMembers) .save(workspaceMember); await queryRunner.manager.getRepository(ChannelMembers).save({ User: returned.id, ChannelId: 1, }); await queryRunner.commitTransaction(); return true; } catch (error) { console.error(error); await queryRunner.rollbackTransaction(); throw error; } finally { console.log('이거 실행됨?'); await queryRunner.release(); } }'이거 실행됨?' 이라는 문자가 출력이 되지 않습니다. 여러번 반복한 후 pgAdmin에서 database activity를 살펴보니 커넥션 pool이 release되지 않고 idle 상태로 되어있습니다.이 때문에 서버의 pool이 가득차서 서버가 종료됩니다. user의 중복검사도 try문 안에 넣으면 해결되는거 같습니다. 🟩 혹시 존재하는 사용자 로직을 try문 밖에 빼신 이유가 있는지 궁금합니다.
-
미해결10주완성 C++ 코딩테스트 | 알고리즘 코딩테스트
4-D 매개변수로 넘기면 왜 안빼도 되는거죠?
ㅠㅠ
-
미해결프로그래밍 시작하기 : 도전! 45가지 파이썬 기초 문법 실습 (Inflearn Original)
phonebook project (name_check, json)
안녕하세요~ 2가지 질문 드립니다. def add_member(d) 함수를 만들 때 name_check를 넣으셨는데, 없어도 함수를 돌리는 데에는 문제가 없어 보입니다. 중간에 체크를 넣으신 이유가 있을까요? json 파일은 'a+' 모드가 없고 'r'과 'w'만 가능한 것으로 알고 있습니다. 초반에 'r'로 읽어오고 종료하기 직전에 'w'로 쓰고 종료해도 괜찮을까요?with open ('../source/45-1.json', 'r') as file: phonebook = json.load(file) < 1~3 중간 내용 동일 > elif menu == '4': with open ('../source/45-2.json', 'w') as out: json.dump(d, out) print('Exit') break
-
미해결10주완성 C++ 코딩테스트 | 알고리즘 코딩테스트
1-N 곱셈 모듈러 관련 문의드립니다.
안녕하세요:)본 문제의 재귀 함수(go 함수) 안에서, b가 홀수인 경우 ret = ret * a % c; 가 되어야 하는 부분에 대해 한번 더 %c 연산을 하지 않아도 되는지 문의드립니다. 예를 들어 (a^5)%c의 경우, [{(a^4)%c}{a%c}]%c 와 같다고 이해했습니다. 이때 b=5 이므로 if(b%2) 에 걸리는데, ret가 (a^4)%c 인 상황에서 (a%c)%c 만큼 추가로 곱해줘야 성립이 되는게 아닌지 궁금합니다!( 만일 (a^4)%c 에 (a%c) 만 곱한다면 그 값이 c 보다 커져서 나머지 연산을 한번 더 해야할 경우도 있지 않나요? ) 감사합니다 :)
-
미해결10주완성 C++ 코딩테스트 | 알고리즘 코딩테스트
1-A 일곱 난쟁이 next_permutation 코드 관련 질문드립니다
안녕하세요:)일곱난쟁이 문제에서 "결과값을 오름차순으로 출력" 해야하는 부분과 관련하여 문의드립니다.next_permutation을 활용하여 경우의 수를 뽑는 경우에, 앞에서 부터 7개 순열을 잘라서 보면 어떤 것은 오름차순으로 되어있지 않은데 혹시 만일 그러한 순열이 답이 되는 경우 sort로 정렬을 다시 안해줘도 되나요? 예를 들어, 본 문제 테스트케이스의 경우[ 7 8 10 13 19 20 23] 이라는 값이 딱 sum이 100인 경우여서 오름차순 그대로 값이 출력이 되지만.. 만약 [7 8 10 13 15 25 19] 가 답이었다고 가정한다면 .. 오름차순이 안되는게 아닌지 해서요! 감사합니다:)
-
미해결
수강기간 연장 부탁드립니다
안녕하세요 강사님,강의 신청해두고 일이 바빠 못듣고 있었는데들으려고 보니 기한이 임박해져서.. 죄송하지만 수강기한 연장 부탁드려도 될까요..?
-
해결됨Google 공인! 텐서플로(TensorFlow) 개발자 자격증 취득
강의 ppt 자료는 어디서 받을 수 있는지요?
강의 ppt 자료는 어디서 받을 수 있는지요? 필기하면서 보고 싶은데 도저히 못 찾겠네요.
-
미해결10주완성 C++ 코딩테스트 | 알고리즘 코딩테스트
3-Q 이렇게 하면 안되는 이유가 뭘까요
http://boj.kr/48d6be65693f4801bc29d65346739e1a
-
해결됨[퇴근후딴짓] 빅데이터 분석기사 실기 (작업형1,2,3)
대응표본검정 실습문제 중 심화문제
제공해주신 쥬피터노트북에서 귀무가설의 부등호 방향이 반대인 것 같은데 혹시 맞을까요?
-
미해결현업 실무자에게 배우는 Kaggle 머신러닝 입문 - ML 엔지니어 실무 꿀팁
강의자료
강의 자료 어딧나요 실습자료 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!1
-
미해결
What are the Best Resources to Locate IELTS Classes Near Me?
Finding IELTS (International English Language Testing System) schools nearby can be crucial if you're studying for this well-known English language competence test. A high IELTS score might lead to endless international opportunities.If you are looking for 'IELTS classes near me' - then AbroAdvice.com has everything you need. However, if you are looking for signs on how to locate the best IELTS courses, then here they are:IELTS official websiteA trustworthy place to start is the official IELTS website (ielts.org). It provides thorough details regarding the test, test locations and approved test prep companies.Find IELTS test centers that are officially registered. Continue reading to know more about study abroad counseling.Online learning platformsIELTS exams are conducted 48 times a year meaning students have more than one opportunity to crack it. To make it convenient consider enrolling in IELTS prep courses online when you are flexible.These portals provide a selection of courses and training resources.Social Media and ForumsJoin neighborhood Facebook groups, Reddit forums, or discussion boards. There you can get suggestions and guidance on IELTS courses nearby.Language Schools and InstitutesNearby language schools or institutes frequently offer IELTS preparation classes. Look for reputable universities with knowledgeable faculty.Colleges and UniversitiesCertain universities and colleges provide IELTS preparation classes to assist prospective students in meeting language requirements. Check with local institutions.Use well-known search engines like Google to look up "IELTS classes near me" or "IELTS preparation courses in [your location]." There are several selections available, along with reviews and ratings.Educational Directories Language schools and tutoring facilities are frequently listed in online directories like Yelp, Yellow Pages, or educational websites. Search for the nearest selections while reading reviews.Groups on MeetupFind language exchange and English-learning groups. Some of these organizations also plan IELTS prep courses.Visit your neighborhood library or community center to see if they provide language or exam preparation programs. They might offer no-cost or inexpensive classes.Tutoring ServicesLook for private IELTS tutors in your neighborhood who can offer customized, one-on-one training. You can discover tutors using websites like Wyzant and Preply.Inquire about ReferralsAsk friends, relatives, coworkers, or classmates who may have participated in IELTS preparation programs for recommendations. Personal recommendations can be beneficial.Local publicationsSome IELTS education providers may run advertisements in regional publications. Look for listings in the classifieds.Find people in your neighborhood who speak English well. Those who are interested in language exchange as language exchange partners can give you promising leads. They can offer advice or suggest classes.Visit Language Schools DirectlyTake the time to go directly to language schools or institutions to meet the staff. Check out the surroundings, and evaluate the level of instruction.Visiting and seeing the authenticity of yourself can help you make better decisions.Selecting the best local IELTS class might improve your chances of getting the target IELTS score. Take no risks with it and ensure you are picking a good site. Follow the tips mentioned above to ensure you pick the best centre.
-
미해결홍정모의 따라하며 배우는 C++
접근지정자와 상속
#include <iostream> #include <cstdio> using namespace std; class Parent { public: Parent() { this->parent_pri = 2; } virtual void pri_print() { printf("%d", parent_pri); } private: int parent_pri; }; class Public_Child : public Parent{}; int main() { Public_Child public_child; public_child.pri_print(); } 이거를 실행하면 비쥬얼 스튜디오에서 2가 출력이 되는데, 클래스 밖의 main 함수에서 public_child.pri_print()에 접근할 수 있는 이유가 public 이기 때문이고, 그 public안의 pri_print함수는 클래스 Parent의 멤버 함수이기 때문에 private로 지정되어 있는 parent_pri에 접근할 수 있기 때문인가요?
-
미해결처음 만난 리액트(React)
chapter_04 시계만들기에서 오류가 납니다ㅠㅠ
설명보고 따라하였는데 시계가 아닌 오류문구만 뜹니다..무엇이 문제일까요?ㅠㅠ
-
미해결10주완성 C++ 코딩테스트 | 알고리즘 코딩테스트
3-L 이렇게 풀면 왜 안될까요?
ㅠㅠhttp://boj.kr/4d01aaf298574b598ed3f4d4412788fc
-
미해결[LV1] Jetpack Compose - UI 연습하기
강사님 닉네임에 생각나는 것이 있어용 ^^
포항에 가니 죽도시장에 개복치회가 있던데 혹시 고향이 포항부근이신감유 *.^
-
해결됨NAVER Cloud Boot Camp - 네이버 클라우드 부트 캠프
linux 계정 변경 후 접속 방법 추가 설명 요청
리눅스 서베에 접속할 때 생성한 키 파일을 이용해서 관리자 비밀번호를 표시하고, 이를 이용해서 로그인하는 방식으로 설명이 되어 있습니다.보안상 root 계정 접속을 막고 새로 만든 계정으로 접속을 하라고 설명을 하셨는데요.새로 만든 계정과 키 파일을 어떻게 연결을 해서 접솓을 하는지에 대한 설명이 없습니다.이 부분에 대해서 추가 설명 부탁드립니다.또한, 서버를 생성할 때 계정을 지정할 수 있는 방법이 있다면 이 부분도 설명 부탁드립니다.
-
미해결함수형 프로그래밍과 JavaScript ES6+
fxts를 배워보려고 합니다.
안녕하세요. 이번에 회사에서 함수형 프로그래밍을 해보려고 하는데, fxts를 사용하려고 합니다.이 강의는 fxjs를 다루고 있는데, fxts를 사용하려 할때도 도움이 될까요?감사합니다.
-
해결됨AWS(Amazon Web Service) 입문자를 위한 강의
[4-5] RDS 실습 - 1부 수업자료
안녕하세요RDS 실습하니깐 안돼서 질문 쪽으로 와봤는데 버전이 바뀌면서 함수이름이 바뀐거같네요. 질문도 같은거 여러개라 그런데 수업자료도 같이 고쳐주실수있을까요?#!/bin/bashyum install httpd php php-mysql -yyum update -ychkconfig httpd onservice httpd startecho "<?php phpinfo();?>" > /var/www/html/index.phpcd /var/www/htmlwget https://aws-learner-storage.s3.ap-northeast-2.amazonaws.com/connect.php connect. php<?php$username = "awslearner";$password = "awslearner";$hostname = "yourhostnameaddress";$dbname = "awslearner";// connection to the database$dbhandle = new mysqli($hostname, $username, $password, $dbname);if ($dbhandle->connect_error) {die("MySQL에 연결할 수 없습니다: " . $dbhandle->connect_error);}echo "MySQL 접속 성공!<br>";// Later, when done with the database connection$dbhandle->close();?> yum install httpd php php-mysql -ywget https://aws-learner-storage.s3.ap-northeast-2.amazonaws.com/connect.php이부분 고쳐야하는건 알겠는데 마지막 줄은 어떻게 바꿔야할지 모르겠어요