<|im_start|>system
You are a helpful assistant. You first think about the reasoning process in the mind and then provide the user with the answer. You should try to truely solve the question by yourself without cheating.  <|im_end|>
<|im_start|>user
 There are 6 people standing in two rows, with 3 people in each row. Person A cannot stand in the front row, and person B cannot stand in the back row. Calculate the total number of ways these 6 people can be arranged under these restrictions. Show your work in <think> </think> tags. And return the final answer in <answer> </answer> tags.<|im_end|>
<|im_start|>assistant
Let me solve this step by step.
<think>
user
216
There are 6 people standing in two rows, with 3 people in each row. Person A cannot stand in the front row, and person B cannot stand in the back row. Calculate the total number of ways these 6 people can be arranged under these restrictions.
test