그래서 나는 다음과 같습니다 중첩 된 사전 및 목록의 큰 데이터 세트를 포함 파이썬 파일이 완전한 데이터 구조를 인쇄하지 :이파이썬은
하는 파이썬 스크립트가 다음recipes = {
"recipe": {
"name": "solar_panel",
"type": "craft",
"ingredients": {
"input": [
"coal_dust",
"glass",
"coal_dust",
"glass",
"coal_dust",
"glass",
"electronic_circuit",
"generator",
"electronic_circuit"
],
"output": {
"item": "solar_panel",
"quantity": 1
}
}
},
"recipe": {
"name": "re_battery",
"type": "craft",
"ingredients": {
"input": [
"nothing",
"insulated_copper_cable",
"nothing",
"tin",
"redstone",
"tin",
"tin",
"redstone",
"tin"
],
"output": {
"item": "re_battery",
"quantity": 1
}
}
}
}
import vanilla
print(vanilla.recipes)
단순히 전체 데이터 구조를 인쇄 하겠지만 실제로는 마지막 하위 항목 (목록의 23-43 행) 만 인쇄합니다. 나는 여기서 명백한 것을 놓치고있는 것처럼 느낀다.
AH, 그건 의미가 있습니다. 이 데이터는 믹스 업이 발생한 방식 인 XML에서 변환되었습니다. – giodamelio
10 분을 기다려야합니다. D. 그런데 빠른 답변 주셔서 감사합니다, 3 분 꽤 놀랍습니다. – giodamelio