2023.DEC.22(FRI) JAVA DAY 15
โ Daily Report ๐ TO-DO LIST submit github blog post lesson assigment: โ
โ Daily Report ๐ TO-DO LIST submit github blog post lesson assigment: โ
โ Daily Report ๐ TO-DO LIST submit github blog post lesson assigment: โ
Error(์ค๋ฅ) ๐ Exception(์์ธ) ๋ ๋ค Throwable์ class ๐ฅ Error(์ค๋ฅ) ์ปดํจํฐ ์์ฒด์ ๋ฌธ์ (cpu, memory ๋ฑ) JVM์์ ๊ธฐ์ธํ ๋ฌธ์ โก๏ธ ์ฝ๋์ ๋ฌธ์ ๊ฐ ์๋ ํต์ ๋ถ๊ฐ๋ฅ โ ํด๋์ค๋ก ๊ด๋ฆฌ๋๊ณ ์๋ค. example: OutOfMemoryError ๐ฅ Exception(์์ธ) ...
โ Daily Report ๐ TO-DO LIST submit github blog post lesson 45, 46 assigment: equals() and == equals()์ == ๋ชจ๋ ๊ฐ์ฒด๋ฅผ ๋น๊ตํ๊ธฐ ์ํด ์ฌ์ฉ equals()๋ ๊ฐ์ฒด์ ๋ฐ์ดํฐ ๊ฐ์ ๋น๊ต ==๋ ๋ฉ๋ชจ๋ฆฌ ๊ฐ์ ๋น๊ต
โ Wrapper Class primitive data type๋ ๊ฐ์ฒด โ primitive type: int, long, float, double, booleanโฆ Wrapper Class๋ ํด๋์ค์ด๊ธฐ ๋๋ฌธ์ ๊ฐ์ฒด์ reference type โญ๏ธ wrapper class: Integer, Long, Float, Double, Boolea...
โ Stack: LIFO LIFO: Last In First Out added and removed from the top of the stack the last to be added will the the first to be removed import java.util.Stack; public class StackExample...
โ Map ์ด๋ค key๋ฅผ ๊ธฐ์ค์ผ๋ก value๋ฅผ ์์๋ด๋ ๊ฒ ์์ ๊ณ ๋ ค ์ ํจ ๊ตฌ์กฐ: key-value ์ฉ๋: key๋ฅผ ๊ธฐ์ค์ผ๋ก value๊ฒ์ ๊ตฌํ์ฒด: HashMap: Array ๊ตฌ์กฐ ๊ธฐ๋ฐ TreeMap: Node ๊ตฌ์กฐ ๊ธฐ๋ฐ ๐ก Map method public class MapInterfaceTest { public stati...
โ Java List ์ฉ๋: ์์๊ฐ ์๋ data collection ์์: ์ผํ๋ชฐ ์ฌ์ดํธ ์ฐ๋ชฉ๋ก ๊ตฌํ class: ArrayList(Array๊ตฌ์กฐ ๊ธฐ๋ฐ) LinkedList(Node๊ตฌ์กฐ ๊ธฐ๋ฐ) class๋ก ๊ตฌํ ๋ด๋ถ์ ์ผ๋ก toString()์ด ํฌํจ๋์ด ์๋ค. ๐ก List์ method public static void ...
โ Collection Framework โ๏ธ ๊ฐ ์๊ตฌ์ํฉ์ ์ ํฉํ ์๋ฃ๊ตฌ์กฐ๋ ๋ค๋ฅด๋ค. ํต์ฌ์์: ๊ฐ์ฅ ์์ฃผ ๋ฐ์ํ๋ ๋ก์ง์ด ์ด๋ค ์ฑ๊ฒฉ์ธ๊ฐ? ์๋ฅผ ๋ค์ด, ๊ณ ๊ฐ์ด ์ค์ ์๋ ์ํฉ(ArrayLsit)๊ณผ ํ์ ์ฑ์ ์ฒ๋ฆฌํ๋ ์ํฉ(LinkedList)์ ํ์ํ ์๋ฃ๊ตฌ์กฐ๋ ๋ค๋ฅผ ๊ฒ์ด๋ค. ๊ณ ๋ ค์์ ์ ํฉํ ์ฉ๋์ธ๊ฐ? ๋ด ์๋์ ๋ง๊ฒ ์ฌ์ฉํ๊ธฐ ์ฌ์ด ๊ตฌ...
โ Generic ํ๋ก๊ทธ๋๋ฐ โ ๋ก์ง์ ๋ค ๋๊ฐ์๋ฐ datatype๋ง ๋ฐ๊พธ๋ ์ฝ๋๋ฅผ ์ง์ผ ํ๋ค๋ฉด? โ object๊ฐ ์ต์์ํด๋ผ์ค๋๊น, object class๋ก ๊ตฌํํด๋ณผ๊น? ๊ทธ๋ฌ๋ ํญ์ downcastingํด์ผํ๋ ํ๊ณ๊ฐ ์๋ค. ๐จ ์์ ํ๊ฒ ๊ฐ์ ์ฝ๋๋ฅผ ์ฌ๋ฌ ์ฐธ์กฐํ์ ์ฌ์ฉํ์ฌ ์ฝ๋ ์ฌ์ฌ์ฉ์ฑ ์ฌ๋ฆฌ๋ ํ๋ก๊ทธ๋จ ๊ธฐ๋ฒ ํ์ ์ ์ผ๋ฐ์ ์ผ๋ก ์ง์ ํ์ง ...