You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
in the code, there are two variables: answer_previous_number_array and answer_previous_number_array2. What's their purpose? It is said in the code that "answer_this_number_check: check answer is correct or not." and "answer_this_hint: used for answer hint", but the former is added into answer_previous_number_array.
So, how does the sentence
if len(list(set(answer_previous_number_array[-min(len(answer_previous_number_array),
args.hint_length):]))) == 1 and count_this>=args.hint_length:
break
work?
The text was updated successfully, but these errors were encountered:
count_this>=args.hint_length: iteration at least args.hint_length times. Usually, the iteration number is 2.
-min(len(answer_previous_number_array), args.hint_length): choose the smaller value between len(answer_previous_number_array) and args.hint_length. Usually, the smallest value is 2.
set(answer_previous_number_array[-min(len(answer_previous_number_array), args.hint_length):]): select the unique value from the last args.hint_length(usually it is 2) elements.
len(list(set(answer_previous_number_array[-min(len(answer_previous_number_array), args.hint_length):]))) == 1: if the length is 1, this suggests that the last args.hint_length elements are the same so that we finish the question.
If there is any further question, please let us know.
Again, thank you very much for your attention to our work, and wish you a good day.
in the code, there are two variables:
answer_previous_number_array
andanswer_previous_number_array2
. What's their purpose? It is said in the code that "answer_this_number_check: check answer is correct or not." and "answer_this_hint: used for answer hint", but the former is added intoanswer_previous_number_array
.So, how does the sentence
work?
The text was updated successfully, but these errors were encountered: