Blogtrottr
Yahoo!奇摩知識+ - 分類問答 - 電腦網路 - 已解決
Yahoo!奇摩知識+ - 分類問答 - 電腦網路 - 已解決 
50% off Print Subscription of USA Today

Get the news delivered to your doorstep. Lock in the savings and receive USA Today for just $0.75 a day.
From our sponsors
python(想設計一個程式)
Apr 2nd 2014, 09:36

想用python設計一個程式,讓使用者輸入key:value為英文:中文的英中翻譯字典,直至輸入0:0結束,最後將其列印出來。

提示一:請參考輸出畫面。
提示二:先取一個空的字典,然後依輸入字串處理是否合乎格式key:value,合則加入,不合則跳過即可。

參考輸出畫面:
請輸入英文:中文字典翻譯字彙(輸入0:0結束) -> dog:狗
請輸入英文:中文字典翻譯字彙(輸入0:0結束) -> god:神
請輸入英文:中文字典翻譯字彙(輸入0:0結束) -> father:爸爸
請輸入英文:中文字典翻譯字彙(輸入0:0結束) -> 123456789
請輸入英文:中文字典翻譯字彙(輸入0:0結束) -> news:新聞
請輸入英文:中文字典翻譯字彙(輸入0:0結束) -> mathematics:數學
請輸入英文:中文字典翻譯字彙(輸入0:0結束) -> 0:0

mathematics | 數學
(______) dog | 狗
(__________)| 爸爸
(_____)news | 新聞
(______)god | 神

This entry passed through the Full-Text RSS service — if this is your content and you're reading it on someone else's site, please read the FAQ at fivefilters.org/content-only/faq.php#publishers.

You are receiving this email because you subscribed to this feed at blogtrottr.com.

If you no longer wish to receive these emails, you can unsubscribe from this feed, or manage all your subscriptions
arrow
arrow
    全站熱搜

    mkmkmklal 發表在 痞客邦 留言(0) 人氣()