-
[안드로이드 스튜디오] Error running 'app': Gradle project sync failed. Please fix your project and try again. / android studio Error while waiting for device: The emulator process for AVD was killed
에러메시지: Error running 'app': Gradle project sync failed. Please fix your project and try again. 또는 android studio Error while waiting for device: The emulator process for AVD was killed 해결 방법 인터넷 연결 되어있는지 확인 File > Settings > Appearance & Behavior > System Settings > Androind SDK SDK Tools 에서 Android Emulator 설치 되어있는지 확인, 업데이트 해야하면 업데이트 한다. 나의 경우에는 이렇게 해서 해결했다. 환경변수 설정도 만져보고 무슨 Grandle? 폴더도 지워보고 ..
2021.03.19 19:53 -
[Python] input()과 sys.stdin
sys.stdin 알고리즘 문제를 풀 때, 파이썬의 input()은 실행시간이 느려서 자주 시간초과가 난다. 이럴때 sys모듈의 stdin을 사용하면 더 빠르게 input이 가능하다.. 고 하는데, 나는 input()과 sys.stdin의 차이점을 알고싶었다. input() vs sys.stdin input() input() 파이썬의 내장함수이고, 공식 문서의 'Built in function'에가면 해당 내용을 읽어 볼 수 있다. input()에 대한 파이썬 공식 문서 If the prompt argument is present, it is written to standard output without a trailing newline. The function then reads a line from ..
2021.02.09 17:02 -
[Leetcode] 641. Design Circular Deque
Leetcode 641. Design Circular Deque https://leetcode.com/problems/design-circular-deque/ Design Circular Deque - LeetCode Level up your coding skills and quickly land a job. This is the best place to expand your knowledge and get prepared for your next interview. leetcode.com Solution class MyCircularDeque: def __init__(self, k: int): self.q = [None] * (k+1) self.max = k+1 self.front = 0 self.re..
2021.01.19 09:52 -
명품자바 programming 13장 실습문제
2번 3번 스레드가 동작을 안 해서 디버깅 돌리고 난리를 쳤는데 스레드 run() 안에 while문을 안 넣어줬던 거였다.... Aㅏ 1. import java.util.Scanner; public class Ex01 { public Ex01() { Scanner scanner = new Scanner(System.in); System.out.print("아무거나 입력"); scanner.nextLine(); scanner.close(); Thread th = new Thread(new PrintThread()); th.start(); } class PrintThread implements Runnable{ @Override public void run() { for (int i=0; i
2020.12.08 06:24 -
명품자바 programming 실습문제 9장
5. import java.awt.Color; import java.awt.Container; import java.awt.GridLayout; import javax.swing.JFrame; import javax.swing.JLabel; public class Ex5 extends JFrame { public Ex5() { super("4x4 Color Frame"); setDefaultCloseOperation(EXIT_ON_CLOSE); Container c = getContentPane(); c.setLayout(new GridLayout(4,4)); for (int i=0; i
2020.12.04 06:06