This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package decorator; | |
/** | |
* 데코레이터 역할 (피자의 값이나 이름의 반환값에 변화를 주기 위해 추가된 데코레이터) | |
*/ | |
public class CheeseTopping extends Topping{ | |
Pizza pizza; | |
public CheeseTopping(Pizza pizza) { | |
this.pizza = pizza; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package Oct; | |
import java.util.ArrayList; | |
import java.util.List; | |
public class 크레인인형뽑기 { | |
public static void main(String[] args) { | |
int[][] board = new int[5][]; | |
board[0] = new int[]{0,0,0,0,0}; | |
board[1] = new int[]{0,0,1,0,3}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.test; | |
public class Contact { | |
String name; | |
String tel; // 010-1111-2222 | |
String gender; | |
String birthDate; // 1991/09/01 | |
public Contact() { |