tubeCoding
Python
Java demo
한국어(ko)
English(en)
한국어(ko)
로그인
회원가입
새 파일
CSV 파일 추가
파일 이름
취소
파일 생성
코드 실행
해당 파일은 텍스트 편집기에서 표시할 수 없습니다.
콘솔 출력
[{"type": "TextFile", "filename": "main.py", "content": "import random, time\r\nimport turtle as t\r\n#\uc0ac\uc6a9\uc790\uc5d0\uac8c \ubc1c\ud45c\uc790 \uba85\ub2e8 \uc785\ub825 \ubc1b\uae30\r\ninput_names = input(\"\ubc1c\ud45c\uc790 \uc774\ub984\ub4e4\uc744 \uc27c\ud45c(,)\ub85c \uad6c\ubd84\ud574\uc11c \uc785\ub825\ud558\uc138\uc694: \")\r\nnames = input_names.replace(\" \", \"\").split(\",\")\r\n# \ubf51\uc744 \uc778\uc6d0 \uc218 \uc785\ub825\r\nn = int(input(\"\ubc1c\ud45c\uc790\ub97c \uba87 \uba85 \ubf51\uc744\uae4c\uc694? (\ucd5c\ub300 \" + str(len(names)) + \"\uba85): \"))\r\nt.title(\"\ubc1c\ud45c\uc790 \ubf51\uae30\")\r\nt. hideturtle()\r\nt. pendown()\r\nfor x in range(10): # 10\ubc88 \uae5c\ube61\uc784\r\n tstr =\"\uc624\ub298\uc758 \ubc1c\ud45c\uc790\ub294 \"\r\n for _ in range(n):\r\n tstr += \"%s \" %names[random.randrange(0, len(names))]\r\n tstr += \"\uc785\ub2c8\ub2e4\"\r\n t.write(tstr, False, \"center\", (\"\ub098\ub214\uace0\ub515\",13, \"bold\"))\r\n t.clear( )\r\n time.sleep(0.3)\r\nt.write(tstr, False, \"center\",(\"\ub098\ub214\uace0\ub515\" , 13, \"bold\"))", "locked": true}]