본문 바로가기

Web & Mobile102

Lecture 29 - Java(10) ArrayList, LinkedList, HashSet, TreeSet, HashMap, File ArrayList 계속 ArrayListEx05 - 2차원 데이터를 저장 2차원 데이터를 저장(행과 열) = 테이블 2차원 배열 ArrayList 2개 : ArrayList안에 ArrayList를 넣는다 ArrayList + 클래스 1 홍길동 010-111-1111 20 서울시 2 박문수 010-222-2222 22 경기도 3 이몽룡 010-333-3333 23 강원도 위 데이터를 2차원 배열 넣고 싶은데 어떻게 하면 될까요? public class ArrayListEx05 { public static void main(String[] args) { // 2차원 데이터를 저장(행과 열) = 테이블 // 2차원 배열 // ArrayList 2개 : ArrayList안에 ArrayList를 넣는다 // Ar.. 2023. 6. 20.
Lecture 28 - Java(9) 로또발생기, StringTokenizer, StringJoiner, Scanner, Arraylist 1. 왜 자바를 써요? - 객체지향성 때문에요 2. 자바프로그램의 분류 - SE(core) / EE(Enterprise) / ME(망함) 3. JDK, JRE(JVM : Java Virtual Machine) - jdk(jdk + jre(jvm)) * jvm이 얼마나 빨라 질 것인가 -> chip ----------------------------------------------------------------------------------------------------------------------- 프로그램 개론(Ch.02~04) 데이터 처리(자료 구조) + 객체 -> 객체 선언 / 사용(Ch.6) -> 객체 지향 프로그램 기법(Ch.7) 은닉(캡슐화 : incapsulation) - 데이터 보.. 2023. 6. 20.
Lecture 27 - Java(8) 추상화, 형변환, 다형성, 예외처리 추상클래스(abstract class) 클래스를 설계도에 비유한다면, 추상클래스는 미완성 설계도에 비유할 수 있다. 미완성 설계도란, 단어의 뜻 그대로 완성되지 못한 채로 남겨진 설계도를 말한다. 클래스가 미완성이라는 것은 멤버의 개수에 관계된 것이 아니라, 단지 미완성 메서드(추상메서드)를 포함하고 있다는 의미이다. 미완성 설계도로 완성된 제품을 만들 수 없듯이 추상클래스로 인스턴스는 생성할 수 없다. 추상클래스는 상속을 통해서 자손클래스에 의해서만 완성될 수 있다. 추상메서드(abstract method) 메서드는 선언부와 구현부(몸통)로 구성되어 있다고 했다. 선언부만 작성하고 구현부는 작성하지 않은 채로 남겨 둔 것이 추상메서드이다. 즉, 설계만 해 놓고 실제 수행될 내용은 작성하지 않았기 때문에.. 2023. 6. 20.
Lecture 26 - Java(7) 주민번호체크, wrapper 클래스, Date, Calendar StringEx02 문자열의 첫문자를 대문자화 // 문자열의 첫문자를 대문자화 // hong gil dong -> "hong gil dong" public class StringEx02 { public static void main(String[] args) { // TODO Auto-generated method stub // 입력값 검사 if(args.length != 1) { System.out.println("1개의 값을 입력하셔야 합니다."); } else { //System.out.println("정상 입력"); String[] names = args[0].split(" "); String result = ""; for(String name : names) { //System.out.print.. 2023. 6. 20.
Lecture 25 - Java(6) 클래스, 접근제어자, 이클립스 환경 구축법 클래스 모듈(X) 패키지(도메인) 클래스 배치 import 패키지명.(.여러개.).클래스 (패키지명) 디렉토리.디렉토리.디렉토리.클래스 has - a : 멤버변수(instance) is - a : 상속 상속 - extends 클래스(한개) : 단일 상속(다중 상속 X) - 생성자와 초기화 블럭은 상속 X - final class - 상속불가 method - 오버라이드 불가 멤버변수/지역변수 - 상수 - 오버라이드(재정의) 조건 : 메서드 이름, 타입, 매개변수가 같아야 한다 - super - super() 접근 제어자(access modifier) 접근 제어자는 멤버 또는 클래스에 사용되어, 해당하는 멤버 또는 클래스를 외부에서 접근하지 못하도록 제한하는 역할을 한다. 접근 제어자가 사용 될 수 있는 곳.. 2023. 6. 20.
Error: Node Sass does not yet support your current environment: OS X 64-bit with Unsupported runtime (83) GraphQL 해보려고 유데미 강사분의 깃허브를 clone 하고 나서 yarn start를 했는데 아래와 같은 문제가 발생 Error: Node Sass does not yet support your current environment: OS X 64-bit with Unsupported runtime (83) 지난번에도 context-API 강의 할때 github clone 하고 이런 상황이 발생해서 해결을 했었는데 기록을 해두지 않아서 어떻게 해결했는지 기억이 가물가물... 그래서 이번에는 해결전이지만 무슨 짓을 했는지 기록하며 진행하기로 계획 1. npm uninstall node-sass 2. npm install node-sass 3. npm rebuild node-sass 했는데 안됨.. 보니.. 2021. 7. 17.
React HOOK을 위한 읽을 거리[중요!!!!] useEffect : https://overreacted.io/ko/a-complete-guide-to-useeffect/ useEffect 완벽 가이드 이펙트는 데이터 흐름의 한 부분입니다. overreacted.io https://react-redux.js.org/api/hooks https://www.robinwieruch.de/react-hooks-fetch-data Hooks | React Redux API > Hooks: the `useSelector` and `useDispatch` hooks` react-redux.js.org https://github.com/ReactTraining/react-router/blob/master/packages/react-router/docs/api/hoo.. 2021. 6. 24.
React Hooks LifeCycle 요약 ComponentDidMount //Class componentDidMount() { console.log('I just mounted!'); } //Hooks useEffect(() => { console.log('I just mounted!'); }, []) ComponentWillUnmount //Class componentWillUnmount() { console.log('I am unmounting'); } //Hooks useEffect(() => { return () => console.log('I am unmounting'); }, []) ComponentWillReceiveProps //Class componentWillReceiveProps(nextProps) { if (nextProp.. 2021. 6. 22.