given 2 lagnauges A,B which are npc. is there a reduction function from A to B $A \leq_PB$ ?
my idea was to say that since they are decideable, we can do this: $$ f(x) = \begin{cases} y \in B & \text{ } if x \in A \\y \notin B & \text{if }x \notin A.\end{cases} $$
is this is correct? or its not something that can be true? / depands on p equal or not equal to np