记单词023

dictionary
词典

skim
撇去浮沫,略读

radius
半径

weed
杂草

overtake
赶上,突然来袭,压倒

plaster
石膏

idle
无聊的,懒散的

cricket
板球

cucumber
黄瓜

beginner
初学者

rusty
生锈的

chalk
粉笔

amplify
扩大,详述

purity
纯净

nevertheless
然而,不过

pea
豌豆

voltage
电压

salute
致意,问候

shepherd
牧羊人,牧师

crow
啼叫

discard
丢弃

dread
恐惧,可怕的人,可怕的事

unexpected
意外的,想不到的

lightly
轻轻地

minus
负的,减的

announcer
广播员

superficial
表面的,肤浅的

probable
很可能的

sponge
海绵

shed
车棚

imprison
使,,,下狱,关闭

gap
差异,缝隙

clasp
扣子

  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
好的,以下是一个简单的背单词单词小程序的实现: ```python import random # 单词类 class Word: def __init__(self, word, meaning): self.word = word self.meaning = meaning # 词库类 class Vocabulary: def __init__(self): self.words = [] # 添加单词 def add_word(self, word, meaning): self.words.append(Word(word, meaning)) # 背单词程序类 class WordLearning: def __init__(self, vocabulary): self.vocabulary = vocabulary self.current_word = None self.score = 0 self.wrong_words = [] # 随机选择一个单词 def get_word(self): self.current_word = random.choice(self.vocabulary.words) # 展示单词并获取用户输入 def show_word(self): print("单词:", self.current_word.word) answer = input("请输入单词的意思:") return answer # 检查用户输入的答案是否正确 def check_answer(self, answer): if answer == self.current_word.meaning: self.score += 1 print("回答正确!") else: self.wrong_words.append(self.current_word) print("回答错误!正确答案为:", self.current_word.meaning) # 展示得分情况 def show_score(self): print("本次得分:", self.score) # 展示错词并重新学习 def review_wrong_words(self): if self.wrong_words: print("以下是你错过的单词:") for word in self.wrong_words: print(word.word, word.meaning) print("重新学习!") self.wrong_words = [] self.score = 0 self.start_learning() else: print("没有错过的单词!") # 开始学习 def start_learning(self): print("开始学习!") while True: self.get_word() answer = self.show_word() self.check_answer(answer) another_word = input("是否继续?(y/n)") if another_word.lower() == "n": break self.show_score() self.review_wrong_words() # 示例 vocabulary = Vocabulary() vocabulary.add_word("apple", "苹果") vocabulary.add_word("banana", "香蕉") vocabulary.add_word("cherry", "樱桃") vocabulary.add_word("orange", "橙子") vocabulary.add_word("pear", "梨子") word_learning = WordLearning(vocabulary) word_learning.start_learning() ``` 这个程序很简单,只有一个学习模式,用户输入单词的意思,程序判断是否正确,最后展示得分情况和错词,并可以重新学习错词。如果需要更多的学习模式和功能,可以根据需要进行扩展。
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值