Week 4 assignment 1 exercise 1

Hi All, I am getting this error " TypeError: unsupported operand type(s) for -: ‘list’ and ‘list’ " in line 24 where I wrote " 24 pos_dist = tf.reduce_sum((anchor - positive)**2, axis=-1)"

The error says that ‘anchor’ and ‘positive’ are lists, and that you can’t subtract two lists using the ‘minus’ operator.

You need to use tf.square() and tf.subtract() in that line of code. Those functions can handle lists.