에서족보
2025년 12월 8일 17:09분
package com.jesusbornd.genesis;
import java.util.*;
/*
* Genesis_36_Chapter_Lv1_V2.java
* Variation: Lineage Tree Engine
* - Edom 계보를 간단한 Tree 구조로 표현
* - parent → children 구조 + 들여쓰기 출력
*/
public class Genesis_36_Chapter_Lv1_V2 {
// --- 1) 트리 노드 모델 ---
static class Node {
String name;
String info; // 혈통 설명(KRV+ESV 핵심)
Node(String name, String info) {
this.name = name;
this.info = info;
}
}
// --- 2) 트리(부모 → 자식 목록) ---
private static final Map<String, List<Node>> TREE = new LinkedHashMap<>();
static {
// 에서(Edom)
TREE.put("에돔(에서)", List.of(
new Node("엘리바", "에서의 아내(엘리바) - 창36:2"),
new Node("바스맛", "에서의 아내(바스맛) - 창36:3"),
new Node("아홀리바마", "에서의 아내(아홀리바마) - 창36:3")
));
// 아들들 (대표 4개만)
TREE.put("엘리바", List.of(
new Node("데만", "엘리바의 아들 데만 - 창36:11"),
new Node("고라", "엘리바의 아들 고라 - 창36:5")
));
TREE.put("바스맛", List.of(
new Node("르우엘", "바스맛의 아들 르우엘 - 창36:13")
));
TREE.put("아홀리바마", List.of(
new Node("여우스", "아홀리바마의 아들 여우스 - 창36:14"),
new Node("야람", "아홀리바마의 아들 야람 - 창36:14")
));
}
public static void main(String[] args) {
System.out.println("[Genesis 36 | Lineage Tree]");
System.out.println("— Lv1~초중급: 간단 트리 구조로 족보 보기 —\n");
printTree("에돔(에서)", 0);
System.out.println("\n[Summary]");
System.out.println("창36장은 에서(Edom)의 가문이 어떻게 민족을 이루는지 보여주는 계보 장이다. "
+ "이스라엘만이 아니라, 다른 민족도 하나님 안에서 ‘역사 속 역할’을 부여받았음을 드러낸다.");
System.out.println("\n[Practice]");
System.out.println("오늘 나는 ‘내 가문·내 이야기’ 속에서 하나님이 주신 위치를 다시 생각해보자.");
}
// --- 3) 트리 출력 (indent 기반 재귀) ---
private static void printTree(String root, int depth) {
indent(depth);
System.out.println("• " + root);
List<Node> children = TREE.get(root);
if (children == null) return;
for (Node child : children) {
indent(depth + 1);
System.out.println("→ " + child.name + " (" + child.info + ")");
printTree(child.name, depth + 2);
}
}
private static void indent(int depth) {
System.out.print(" ".repeat(Math.max(0, depth)));
}
}
#### Genesis_36_Chapter_Lv1_V2.py
#### Variation: Lineage Tree Engine (초중급)
from dataclasses import dataclass
from typing import Dict, List
@dataclass
class Person:
name: str
info: str
# 트리 자료구조
TREE: Dict[str, List[Person]] = {
"에돔(에서)": [
Person("엘리바", "에서의 아내 — 창36:2"),
Person("바스맛", "에서의 아내 — 창36:3"),
Person("아홀리바마", "에서의 아내 — 창36:3"),
],
"엘리바": [
Person("데만", "엘리바의 아들 — 창36:11"),
Person("고라", "엘리바의 아들 — 창36:5"),
],
"바스맛": [
Person("르우엘", "바스맛의 아들 — 창36:13"),
],
"아홀리바마": [
Person("여우스", "아홀리바마의 아들 — 창36:14"),
Person("야람", "아홀리바마의 아들 — 창36:14"),
],
}
def print_tree(root: str, depth: int = 0):
print(" " * depth + f"• {root}")
children = TREE.get(root)
if not children:
return
for child in children:
print(" " * (depth + 1) + f"→ {child.name} ({child.info})")
print_tree(child.name, depth + 2)
def main():
print("[Genesis 36 | Lineage Tree]")
print("— Python Variation: 간단 트리 구조로 족보 시각화 —\n")
print_tree("에돔(에서)")
print("\n[Summary]")
print("에서(Edom)의 가문이 한 민족(Edom)을 이루는 과정이 펼쳐지는 장이다. "
"이는 하나님이 모든 족속을 역사 안에서 다루신다는 증거이다.\n")
print("[Practice]")
print("오늘 내 가정·가문 속에 주신 하나님의 자리와 목적을 묵상해보자.")
if __name__ == "__main__":
main()
Search
Categories
← 목록으로
Comments
에돔의 가지가 뻗어 나가듯, 하나님이 모든 가문을 향해 씨줄과 날줄을 짜고 계셨다는 사실이 다시 보이네요. 기록 속 이름 하나하나도 주님의 섭리가 스며 있는 줄기였습니다. 🌿