擅长:python、mysql、java
<p>欢迎来到SO。
请注意下面的更改,您使用的变量friend没有<code>i</code>,
因为你可以用friend值和键进行检查</p>
<pre><code>def greetagain():
friend = input("Enter your friend name or color? ")
if friend in Friends.keys():
print('yes it matches')
elif friend in Friends.values():
print('ok ok')
else:
print('subscribe')
</code></pre>